Chapter 6 The Linear Model II: Logistic Regression

In the previous chapter, we introduced the linear model, and showed how we can use it to model continuous dependent variables (\(Y\)), using a combination of both continuous and categorical indepdent variables (\(X\)).

In this chapter we will discuss expanding our toolkit to use a different type of regression, logistic regression, to model categorical dependent variables (\(Y\)). For now, we only consider binary dependent variables (such as Yes/No Decisions, True/False classifications, etc), although there are also extensions to categorical dependent variable with multiple levels (e.g., multinomial regression).

The learning objectives for this chapter are:

  • Readers should understand and be able to use logistic regression to estimate categorical dependent variables (e.g., to perform classification).
# Load the libraries we'll use in this chapter
library(tidyverse)