See the math behind testing & treatment
Watch a population flow through a test and a treatment into outcomes. Change any input and
every view updates live — from false positives and predictive value to who is actually
helped or harmed. No verdicts, just the numbers.
Worth the Test is a free, interactive calculator and visualizer for
medical-screening statistics: positive and negative predictive value (PPV / NPV),
sensitivity, specificity, likelihood ratios (LR+ / LR−), Bayes’ theorem, the Fagan
nomogram, false-positive rates, serial (repeat) testing, and number-needed-to-treat,
-harm, and -screen (NNT / NNH / NNS). Set the prevalence, the test’s accuracy, and a
treatment’s benefit and harm, then watch a single cohort flow from
population → test → treatment → outcome.
What this tool shows
- A live Population → Test → Treatment → Outcome cohort cascade
- A 2×2 confusion matrix (true / false positives and negatives)
- A Bayes probability tree with a PPV read-out
- PPV & NPV plotted against prevalence — the base-rate fallacy, made visible
- A Fagan nomogram: pre-test probability → likelihood ratio → post-test probability
- Serial / repeat-testing cumulative false-positive risk (1 − specificityn)
- Bayesian updating with a Beta-Binomial posterior and 95% credible interval
- Who is helped, harmed, or unchanged — with NNT / NNH / NNS
Key terms
- Prevalence (pre-test probability)
- How common the condition is in the group being tested. The starting point for everything downstream.
- Sensitivity
- Of people who have the condition, the share the test correctly flags positive.
- Specificity
- Of people who do not have it, the share the test correctly clears.
- PPV / NPV
- Given a positive (or negative) result, the chance it is right. Unlike sensitivity/specificity, these depend heavily on prevalence.
- Likelihood ratio (LR)
- How much a result shifts the odds. LR+ for a positive, LR− for a negative — and they do not depend on prevalence.
- NNT / NNH
- Number needed to treat for one person to benefit; number needed to harm for one to be harmed.
- NNS
- Number needed to screen for one person to be helped — screening, testing, treatment, and outcomes all folded together.
The formulas
- PPV and NPV are computed with Bayes’ theorem from prevalence, sensitivity, and specificity.
- LR+ = sensitivity / (1 − specificity)
- LR− = (1 − sensitivity) / specificity
- NNT = 1 / absolute risk reduction (ARR)
- NNS = people screened ÷ people helped
Educational model — not medical advice. It illustrates the statistics of
testing and treatment; it does not describe any specific real-world test.
Privacy & cookies