Description Usage Arguments Value Examples
: Given a list of logistic regressions, *performed using glm()* format, return and optionally, write the results side-by-side to csv.
1 2  | multiformat_glm(glm_list, output_file = NA, formula_list = NA,
  title_list = "", ndigit = 5)
 | 
glm_list | 
 a list() of glm model objects (list of glm objects)  | 
output_file | 
 the file path (with ".csv" extension) to write the results to, if no value provided, no output file will be created (character)  | 
formula_list | 
 optional list of custom formulae to provide to print in results (code pulls regression formula call by default) (list of character)  | 
title_list | 
 optional list of titles for each regression in the list to write atop output file (blank by default) (list of character)  | 
ndigit | 
 level of precision in output, 5 by default (integer)  | 
matrix containing formatted results from the provided regression list (matrix)
1 2 3 4 5 6 7 8  | dem_temp <- copy(dem)
dem_temp[, died := 0, ]
dem_temp[tolower(vital_status) %like% "deceased", died := 1, ]
glm_age             <- glm(died ~ age, data = dem_temp)
glm_age_gender      <- glm(died ~ age + gender, data = dem_temp)
glm_age_gender_race <- glm(died ~ age + gender + race, data = dem_temp)
glm_list            <- list(glm_age, glm_age_gender, glm_age_gender_race)
multiformat_glm(glm_list = glm_list)
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.