Chapter 1: Classical ML

Capstone: churn with survival analysis

Questions about churn, sign-ups and machine failures are common in interviews. Each one is about the time until an event, and many customers have no event yet. Interviewers want to hear that these customers still count, and how a feature changes the risk of cancelling.

16 minInteractive lessonChapter 1: Classical MLLesson 21 of 21

What you will learn

  • Explain censoring and why dropping censored rows biases the answer
  • Compute a Kaplan-Meier curve step by step
  • Read a Cox hazard ratio as a multiplier on risk, not on lifetime

Key terms

censored
a customer whose cancel you have not seen yet
Y
the months you watched a customer
δ (delta)
1 if you saw the cancel, 0 if not

Prerequisites

Take PCA: keeping the most spread first. It comes right before this lesson in the course.

Where this lesson picks up: In the PCA lesson, you kept the few directions with the most spread. This last lesson of the chapter goes back to the churn story from the first lesson. Many customers have not cancelled yet, so what do you do with them?

What comes next

Chapter 2 starts deep learning, where a model learns its own features from raw data such as images.

Next lesson: Forward pass: layers, activations and shapes

More lessons in this part

Take the lesson

Short cards, one idea at a time, with quick checks as you go.