Week 5 — Lesson 4: Confusion matrix, precision, recall, F1

3 min

A yes/no prediction on a NorthPeak machine can be right in two ways and wrong in two ways. A caught fault sends a technician to a real problem. A false alarm costs one visit. A missed fault costs downtime and a repair, about 1,160 CAD on average in incidents.csv. The confusion matrix counts those four cases on the test quarter, and precision, recall and F1 summarise them. F1 is the harmonic mean of precision and recall (a mean that stays low when one of the two numbers is low). This lesson reads the matrix of the Lesson 3 logistic regression cell by cell and shows why accuracy alone hides the real story.

Preview — the rest of the lesson is for enrolled readers.

Already enrolled with a code?

Your access is tied to your account, not to this link. Sign in with the same email you used in class: your course is waiting, no need to enter the code again.

Sign inNo account yet? Create one
This lesson is part of the “Week 5 — Regression, classification and evaluation” module

The first modules of the course are open to everyone. For the rest you have three options: buy this course once and for all, subscribe, or enter the code handed out in class.

Are you a student on this course?

The code is tied to your account: sign in or create an account and it will be applied automatically when you come back.

No account yet? Create one