Open the Probability Simulator's diagnostic-test panel and read the posterior off a highly accurate test for a rare disease, and predict — before you read them off the screen — the probability you are actually sick given a positive result P(D|+), the total probability of a positive P(+), how many of a population test positive, and how that same posterior changes when the disease is common.
A test that is 99% sensitive and 99% specific sounds nearly perfect. But when only 1% of people have the disease, a positive result means the disease is present barely half the time — because the 99% of healthy people produce so many false positives that they match the true positives one-for-one. This is the base-rate effect: the answer depends on how common the disease is (prev), not on the test alone. Bayes' theorem makes it exact, and the confusion counts make it concrete — P(D|+) is not the same as the test's accuracy.
Open the Probability Simulator and use the diagnostic-test panel (the one with prevalence, sensitivity and specificity sliders and a confusion table). Each step names the one thing to set; leave the rest.
Test panel -> prev = 1%, sens = 99%, spec = 99% Population N = 100000
Read off -> P(D|+), P(+), TP, FP, count-based posterior TP/(TP+FP)
Watch the test readout for the exact posterior P(disease | +) and the total probability P(+), and the confusion table for the true-positive and false-positive counts and the posterior they imply. Every number you predict is printed there.
Set prev = 1%, sens = 99%, spec = 99%. Predict the posterior P(D|+) — the chance you truly have the disease given a positive test — then read the test readout.
The readout shows P(D|+) = 0.5 — exactly a coin flip, despite a test that is right 99% of the time. That is the base-rate surprise.
Keep the same settings. Predict the total probability of a positive result P(+) — across the whole population, sick or healthy — then read it off.
The readout shows P(+) = 0.0198 — about 1.98% test positive. Half of those come from the healthy 99%, which is why a positive is only half convincing.
Set the population to N = 100000 and read the confusion table. Predict how many people are true positives — sick and flagged — then read the TP cell.
The table shows TP = 990 true positives — of the 1000 sick people in 100000, the 99% sensitivity catches 990.
Same settings, same population. Now predict how many people are false positives — healthy but flagged — then read the FP cell.
The table shows FP = 990 false positives — the same count as the true positives. Of the 99000 healthy people, 1% are wrongly flagged, and that equals the 990 real cases.
Read the count-based posterior the table reports: TP/(TP+FP). Predict it from the two counts you just read — 990 and 990 — then read it off.
The count-based posterior is 990/1980 = 0.5 — identical to the exact Bayes value from step 1. The paradox is real arithmetic, not a rounding artefact.
Now raise prev = 50% and set sens = 90%, spec = 80%. Predict the posterior P(D|+) — with a common disease, is a positive more trustworthy?
The readout jumps to P(D|+) = 0.818 — even with a weaker test, a positive is now trustworthy. The base rate, not the test, drove the whole surprise.
Everything above is waiting in the Probability Simulator. Slide the prevalence down and watch the posterior collapse while the test stays 99% accurate; slide it back up and watch a positive become trustworthy again; and read the confusion table to see the true and false positives match one-for-one. The test never changed — the base rate did.
- Read the posterior P(D|+) = 0.5 for a 99%-accurate test on a 1% disease — a coin flip
- Found the total probability of a positive P(+) = 0.0198 at those same settings
- Counted TP = 990 true positives in a population of 100000
- Counted FP = 990 false positives — matching the true positives one-for-one
- Confirmed the count-based posterior 990/1980 = 0.5 agrees with the exact Bayes value
- Raised the prevalence to 50% and watched P(D|+) climb to 0.818 — proof the base rate, not the test, drove the surprise