Description Usage Arguments Value Examples
reports mean value for all numeric and logical variables in a data frame
1 |
df |
a tibble |
group |
(optional) single grouping variable. If used, mean by group will be spread across columns. |
round |
(optional) specify number of digits to round means to. Default is no rounding. |
na.rm |
(optional) a logical value indicating whether NA values should be stripped before the computation proceeds. Unlike base, here I default to TRUE |
a tibble with one row per variable in original datset, values are mean
1 2 3 4 | summarize_mean(df = airquality)
summarize_mean(df = airquality, group = Month)
summarize_mean(df = airquality, group = Month, round = 3)
summarize_mean(df = airquality, na.rm = FALSE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.