Machine Learning · module 03 of 12

Logistic Regression & Classification

Lessons

About This Lesson

Where linear regression predicts a number, classification predicts a category: spam or not spam, churn or stay, disease or healthy. Logistic regression is the standard starting point. Despite its name, it is a classification model that outputs a probability between 0 and 1.

You'll see how the logistic (S-shaped) function turns a linear equation into a probability, how a decision threshold turns that probability into a class, and how to interpret the model's coefficients as log-odds. Then you'll build a classifier in Python with scikit-learn.

Watch the videos in order, then follow along in your own notebook. When you're done, continue on to Evaluation Metrics.

Lessons

3 videos
01

StatQuest: Logistic Regression

How logistic regression differs from linear regression: predicting binary outcomes with probabilities, the S-shaped logistic function, and classification.

02

Logistic Regression Details: Coefficients

How to make sense of logistic regression coefficients, which are based on log(odds) and log(odds ratios).

03

Logistic Regression (Binary Classification) in Python

A hands-on tutorial using scikit-learn's LogisticRegression class to solve a binary classification problem in Python.