Precision and RecallPrecision and Recall
Accuracy mixes all four boxes together. Precision and recall each ask one sharper question. At threshold 50, the camp's confusion matrix is:
| Test: positive | Test: negative | |
|---|---|---|
| Has dengue | TP = 9 | FN = 1 |
| Healthy | FP = 9 | TN = 181 |
Both scores come from two different piles of people:
The top pile is everyone the test called positive: 9 real cases and 9 false alarms. The bottom pile is everyone who really had dengue: the same 9 caught, plus 1 missed patient.
Precision looks at the top pile and asks: when the test says dengue, how often is it right? Of the 9 + 9 = 18 people who tested positive, 9 really had dengue.
Recall looks at the bottom pile and asks: of everyone who really had dengue, how many did the test catch? Of the 10 patients, 9 were caught.
So a positive result is right only half the time, but the test catches 90 % of the cases. And the lazy model? It never says positive, so it catches
Note
Doctors call recall sensitivity. The lazy model has no positives at all, so its precision would be — not defined.
Moving the Threshold
Dr. Anjali chooses the threshold. Here everyone sits on the score line: patients with dengue above it, healthy people below. Everyone at or to the right of the amber threshold tests positive, and the people the test gets wrong turn red. Drag the threshold and complete the three missions.
Lower the threshold and recall rises — but more healthy people cross the line, so precision falls. Raise it and precision rises — but patients slip through. No threshold makes both perfect at once. This tug-of-war is the precision–recall trade-off.
Which Mistake Is Worse?
At the dengue camp a miss is far worse than a false alarm: a false alarm costs one extra lab test, a miss can cost a life. So Dr. Anjali keeps the threshold low and cares most about recall.
Other jobs are the other way round. Sort each job by the mistake it can least afford.