quantify_numeric: Quantify Numeric Variable

Description Usage Arguments Value Examples

Description

This function allows you to calculate mean and sd for a numeric variable

Usage

1
2
quantify_numeric(covariate, df, grouping_var, num_display = "PM",
  show_pval = TRUE, digits = 1)

Arguments

covariate

Numeric variable of interest

df

Dataset containing covariate

grouping_var

Variable to group by (will be columns of table)

num_display

How should results be displayed? ('PM' for mean +- sd, 'PRS' for mean (sd))

show_pval

Logical. Should the p-value results be displayed?

digits

Number of digits to round decimals to

Value

A data frame summarizing mean/sd of covariate at each level of grouping variable

Examples

1
2
3
4
## Not run: 
quantify_numeric(covariate = age, df = obpv_baseline, grouping_var = obpv_quintile, digits = 1)

## End(Not run)

jjwillard/wfbmcphsr documentation built on May 14, 2019, 5:01 a.m.