knitr::opts_chunk$set( collapse = TRUE, comment = "#>", fig.path = "tools/README-" ) options(tibble.width = Inf)
Tools for building binary logistic regression models
Tools designed to make it easier for users, particularly beginner/intermediate R users to build logistic regression models. Includes comprehensive regression output, variable selection procedures, model validation techniques and a 'shiny' app for interactive model building.
# Install blorr from CRAN install.packages("blorr") # Install development version from GitHub # install.packages("devtools") devtools::install_github("rsquaredacademy/blorr") # Install the development version from `rsquaredacademy` universe install.packages("blorr", repos = "https://rsquaredacademy.r-universe.dev")
blorr uses consistent prefix blr_*
for easy tab completion.
library(blorr) library(magrittr)
blr_bivariate_analysis(hsb2, honcomp, female, prog, race, schtyp)
blr_woe_iv(hsb2, prog, honcomp)
# create model using glm model <- glm(honcomp ~ female + read + science, data = hsb2, family = binomial(link = 'logit'))
blr_regress(model)
blr_model_fit_stats(model)
blr_confusion_matrix(model)
blr_test_hosmer_lemeshow(model)
blr_gains_table(model)
model %>% blr_gains_table() %>% plot()
model %>% blr_gains_table() %>% blr_roc_curve()
model %>% blr_gains_table() %>% blr_ks_chart()
blr_lorenz_curve(model)
If you encounter a bug, please file a minimal reproducible example using reprex on github. For questions and clarifications, use StackOverflow.
Please note that the blorr project is released with a Contributor Code of Conduct. By contributing to this project, you agree to abide by its terms.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.