summarize_variable: Compute summary statistics for a variable.

View source: R/variable_summaries.R

summarize_variableR Documentation

Compute summary statistics for a variable.

Description

Compute summary statistics, such as the mean or median, for a variable, potentially within various groups.

Usage

summarize_variable(data, formula, ..., .args = list())

summarise_variable(data, formula, ..., .args = list())

Arguments

data

a data frame containing the variables appearing in formula.

formula

an object of class "formula": a symbolic description identifying the response and the predictors of interest.

...

a comma separated list of functions, each of which computes a statistic of interest.

.args

a named list of additional arguments to be added to all function calls.

Value

data.frame containing the values of interest

Examples

summarize_variable(mpg ~ am, data = mtcars, mean, median)


reyesem/IntroAnalysis documentation built on March 29, 2025, 3:29 p.m.