model_stats | R Documentation |
Return a named list of estimates, standard errors, and p-values for one or more regression models.
model_stats(...)
... |
Either a single regression model object, or multiple named models, e.g., m1 = m1, m2 = m2, ... |
Uses the tidy functions from broom and broom.mixed to return a named list of model stats that can be easily used inline in rmarkdown documents.
A named list of model parameters and statistics
reexports
glue
## Not run:
if(interactive()){
m1 <- lm(mpg ~ hp, mtcars)
m2 <- lm(mpg ~ wt, mtcars)
x <- model_stats(m1 = m1, m2 = m2)
x$m1$hp$estimate
x$m1$hp$str # formatted beta coefficient with 95% CI.
}
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.