@@ -15,14 +15,14 @@ knitr::opts_chunk$set(
1515)
1616```
1717
18- ### Introduction
18+ ## Introduction
1919
2020The blorr package offers tools for building and validating binary logistic regression models. It
2121is most suitable for beginner/intermediate R users and those who teach statistics using R. The API
2222is very simple and most of the functions take either a ` data.frame ` /` tibble ` or a ` model ` as input. ** blorr** use
2323consistent prefix ** blr_ ** for easy tab completion.
2424
25- ## Installation
25+ ### Installation
2626
2727You can install ** blorr** using:
2828
@@ -42,7 +42,7 @@ library(blorr)
4242library(magrittr)
4343```
4444
45- ### Data
45+ ## Data
4646
4747To demonstrate the features of blorr, we will use the bank marketing data set.
4848The data is related with direct marketing campaigns of a Portuguese banking
@@ -52,7 +52,7 @@ product (bank term deposit) would be ('yes') or not ('no') subscribed. It
5252contains a random sample (~ 4k) of the original data set which can be found
5353at https://archive.ics.uci.edu/ml/datasets/bank+marketing .
5454
55- ### Bivariate Analysis
55+ ## Bivariate Analysis
5656
5757Let us begin with careful bivariate analysis of each possible variable and the
5858outcome variable. We will use information value and likelihood ratio chi square
@@ -102,7 +102,7 @@ blr_woe_iv_stats(bank_marketing, y, job, marital, education)
102102` blr_woe_iv() ` and ` blr_woe_iv_stats() ` are currently avialable for categorical
103103predictors only.
104104
105- ### Stepwise Selection
105+ ## Stepwise Selection
106106
107107For the initial/ first cut model, all the independent variables are put into
108108the model. Our goal is to include a limited number of independent variables
@@ -133,6 +133,8 @@ model %>%
133133 plot()
134134```
135135
136+ ## Regression Output
137+
136138### Model
137139
138140We can use bivariate analysis and stepwise selection procedure to shortlist
@@ -146,8 +148,6 @@ model <- glm(y ~ age + duration + previous + housing + default +
146148 family = binomial(link = 'logit'))
147149```
148150
149- ### Regression Output
150-
151151Use ` blr_regress() ` to generate comprehensive regression output. It accepts
152152either of the following
153153
@@ -175,7 +175,7 @@ blr_regress(y ~ age + duration + previous + housing + default +
175175 loan + poutcome + job + marital, data = bank_marketing)
176176```
177177
178- ### Model Fit Statistics
178+ ## Model Fit Statistics
179179
180180Model fit statistics are available to assess how well the model fits the data
181181and to compare two different models.The output includes likelihood ratio test,
0 commit comments