
Explain like I'm five
Imagine you have a fruit-sorting machine that puts apples in one bin and oranges in another. A confusion matrix is like a scorecard that tells you how many times it correctly sorted each fruit, and how many times it mistakenly put an apple with the oranges or an orange with the apples.

Why it matters
It matters because it reveals not just overall accuracy but specific types of errors, like false alarms or missed detections. You encounter it in medical tests, spam filters, and any AI that classifies things.

Common misconception
Many people think a confusion matrix is just about how 'confused' the model is, but it's actually a clear breakdown of correct and incorrect predictions. The name comes from the matrix showing where the model gets 'confused' between classes, not from being confusing itself.

Formal definition
A confusion matrix is a specific table layout that allows visualization of the performance of a supervised learning classification algorithm. Each row represents the instances in an actual class, while each column represents the instances in a predicted class, with cells showing counts of true positives, true negatives, false positives, and false negatives.