tidy_wrap: Tidies regression object based on class

Description Usage Arguments Details

Description

The tidy_wrap() function has two primary functions. First, using either broom::tidy or broom.mixed::tidy (depending on model input class) the regression model object is converted into a data frame. It then adjusts the output for use in the rest of fmt_regression.

Usage

1
tidy_wrap(x, exponentiate, conf.level)

Arguments

x

regression model object

exponentiate

logical argument passed directly to broom::tidy or broom.mixed::tidy.

conf.level

confidence level passed directly to broom::tidy or broom.mixed::tidy.

Details

The output of broom::tidy or broom.mixed::tidy will often include additional information that will not be included in a printed table from fmt_regression() (e.g. scale parameters, random effects, etc.). This simple helper function deletes extraneous rows from the output. It also adds a column of NAs if the model does not calculate p.values, since the rest of fmt_regression() depends on having a column called p.value.


ddsjoberg/gtsummary-v0.1 documentation built on June 4, 2019, 7:48 a.m.