Learn R Programming

fifer (version 1.1)

SummarizeContinuousDefault: Summarize a continuous vector with mean plus/minus standard deviation

Description

Summarize a continuous variable with mean plus/minus standard deviation.

Usage

SummarizeContinuousDefault(x, group = rep(1, length(x)), decimal = 2,
  latex = TRUE, na.rm = TRUE, ...)

Arguments

x
Vector of values.
group
Group identifier to return summaries by group.
decimal
The number of decimal values to format the results; defaults to 2.
latex
Return LaTeX characters if TRUE; for example, the LaTeX code for the plus-minus symbol.
na.rm
Remove missing values if TRUE.
...
Nothing.

Value

Formatted text of mean plus/minus standard deviation in a vector or matrix.

Details

Default continuous.summary.function for use in SummarizeVar. Returns formatted text of mean plus/minus standard deviation, possibly by group. For use in construction of demographics tables.

Examples

Run this code
SummarizeContinuousDefault(x=c(rnorm(100, 5), rnorm(100, 0)), group=rep(0:1, each=100))

Run the code above in your browser using DataLab