

#DPLYR SUMMARIZE HOW TO#
For example, instead ofĪcross(a:b, ~ mean(.x, na.rm = TRUE)).namesĪ glue specification that describes how to name the outputĬolumns. Once per across() or once per group? Instead supply additional argumentsĭirectly in. because it's not clear when they should be evaluated: To access the current column and grouping keys respectively.Īdditional arguments for the function calls in. Within these functions you can use cur_column() and cur_group() To each column, and the output is named by combining the function nameĪnd the column name using the glue specification in. List(mean = mean, n_miss = ~ sum(is.na(.x)). ~ mean(.x, na.rm = TRUE)Ī named list of functions or lambdas, e.g.


summarise() or mutate()).fnsįunctions to apply to each of the selected columns.Ī purrr-style lambda, e.g. You can't select grouping columns because they are already automatically
