summarize_stats: mean, sd, min, max of variables

Description Usage Arguments Details Value Examples

Description

returns the mean, sd, min and max of a list of variables. By default passes na.rm = TRUE. Respects grouping of input data.

Usage

1
summarize_stats(tbl, ..., na.rm = TRUE)

Arguments

tbl

A tbl

...

variables to summarize

na.rm

logical value indicating whether NA values should be stripped before the computation proceeds. Default is TRUE

Details

This function respects grouping. If the tbl is grouped, the output will be as well.

Value

a long table with one row per variable. Columns are variable, mean, sd, min and max.

Examples

1
2
summarize_stats(airquality, Ozone, Solar.R, Wind, Temp)
summarize_stats(airquality %>% dplyr::group_by(Month), Ozone, Solar.R, Wind, Temp)

williamlief/liefTools documentation built on Jan. 1, 2020, 6:48 p.m.