The Daily Reckoning
How Can a 99%-Sensitive Test Give Mostly False Alarms?
A positive result reverses the question a test was designed to answer—and the condition's rarity can dominate the answer.
- Difficulty
- Foundational
- Area
- Probability and statistics
- Reading time
- 9 minutes
- Prerequisites
- Percentages · Fractions · The probability of one event given another
Imagine a screening test with 99% sensitivity. Among people who truly have the condition, the test correctly flags 99 out of every 100. You receive a positive result.
Does that mean there is a 99% chance you have the condition?
No. For one plausible set of numbers, the chance is only one in six.
This lesson uses an invented test—not a recommendation about any real assay—to isolate the mathematics. The test has 99% sensitivity, 95% specificity, and is used in a population where 1% of people have the condition. Specificity is the percentage of people without the condition who correctly test negative. A specificity of 95% also means that 5% of people without the condition receive false positive results.
Count people before manipulating symbols
The interactive grid below represents 10,000 people. Each row contains 100 people, so one row equals one percentage point of prevalence. Prevalence means the percentage of this population that has the condition before anyone’s test result is known.
10,000-person test bench
Change how rare the condition is
The imagined test keeps 99% sensitivity and 95% specificity. Arrow keys adjust a focused slider.
At 1% prevalence, only the first row contains people who have the condition. Nearly that whole row becomes true positives. The five pink columns below it are false positives drawn from the much larger group without the condition. A small error rate applied to 9,900 people can outweigh an excellent detection rate applied to 100 people.
Move the prevalence slider. The sensitivity and specificity do not change, but the meaning of a positive result changes substantially. The population being tested supplies information before the assay does.
Two questions that sound alike
Let denote the event that a person has the condition, and let denote the event that the person receives a positive test result.
Sensitivity answers this question:
The vertical bar in means “given that.” The expression says: among people known to have the condition, what fraction test positive?
After receiving a positive result, however, the patient wants the probability in the other direction:
That expression asks: among people known to have tested positive, what fraction have the condition? Reversing the order around the vertical bar changes the group being counted. In general,
The second probability is called the positive predictive value in diagnostic testing. The National Library of Medicine’s diagnostic-testing overview defines it as the number of true positives divided by all positive results and notes that prevalence affects predictive values.
Bayes’ theorem turns the question around
For this two-outcome testing problem, Bayes’ theorem gives
Every symbol has a concrete role:
- is the prevalence, or prior probability of the condition.
- is the probability of not having the condition. The symbol means “not.”
- is the sensitivity.
- is the false positive rate, equal to one minus the specificity.
- is the positive predictive value we want.
The numerator counts the probability of being both affected and positive. The denominator counts every route to a positive result: a true positive route plus a false positive route.
Worked example: 10,000 tests
Begin with the 1% prevalence rather than the positive result.
Step 1: Divide the population by condition status.
Among 10,000 people, 1% have the condition:
The remaining number without the condition is
Step 2: Apply the 99% sensitivity only to the 100 affected people.
The number of true positives is
One affected person receives a false negative result.
Step 3: Apply the 95% specificity only to the 9,900 unaffected people.
A 95% specificity leaves a 5% false positive rate. The number of false positives is
Step 4: Look only at positive results.
There are true positives and false positives, for a total of
positive results. Therefore
The 99% sensitivity was not misleading; it answered a different conditional question. The surprise comes from neglecting the base rate, another name for the 1% prevalence known before the result.
The same arithmetic fits directly into Bayes’ theorem:
The two appearances of in the first line have different meanings: the first is sensitivity, while the second is , the fraction of the population without the condition.
Try two variations
Problem 1
Keep the same 99% sensitivity and 95% specificity, but suppose prevalence rises to 10%. Among 10,000 people, what is the positive predictive value?
Reveal the solution
At 10% prevalence, people have the condition and do not.
The number of true positives is
The number of false positives is
There are positive results. The positive predictive value is
The test characteristics stayed fixed. Raising the prevalence from 1% to 10% raised the positive predictive value from 16.7% to 68.75%.
Problem 2
Return to 1% prevalence and 99% sensitivity. What specificity is needed for exactly half of all positive results to be true positives?
Reveal the solution
Among 10,000 people, the test produces true positives. For true positives to make up exactly half of positive results, the number of false positives must also be .
The false positive rate must therefore be
Specificity is one minus the false positive rate:
At 1% prevalence, raising specificity from 95% to 99% raises the positive predictive value from one sixth to one half.
A theorem published by a second author
Thomas Bayes did not publish the work now attached to his name. Bayes, an English Presbyterian minister, died in 1761. Richard Price found an unpublished probability manuscript among Bayes’ papers, edited it, wrote an introduction, and communicated it to the Royal Society. The resulting 1763 paper in Philosophical Transactions asked how observed successes and failures should change an estimate of an unknown chance.
Price’s role complicates the familiar eponym. He supplied more than clerical delivery, and his introduction attached a theological purpose to the calculation: recurring order, Price argued, gave reason to infer stable causes and ultimately an intelligent cause. That claim belongs to Price’s introduction; surviving evidence does not establish it as Bayes’ own reason for doing the mathematics.
Price also belonged to the political life of eighteenth-century Britain. The Stanford Encyclopedia of Philosophy describes him as a dissenting minister who campaigned against penalties on religious nonconformists and supported the American and French revolutions. Edmund Burke attacked Price’s defense of the French Revolution; Thomas Paine and Mary Wollstonecraft answered Burke. The 1763 probability paper concerns induction, not those political campaigns, but the person who brought it into print was not an apolitical courier.
Pierre-Simon Laplace appears to have developed inverse probability without knowing Bayes’ paper, although the surviving evidence does not settle that point. His first major paper on the subject appeared in 1774. Laplace later used probabilistic inference on population data, including birth ratios and estimates of France’s population. The Encyclopedia of Mathematics account of Laplace notes that his work helped show how methods used for physical phenomena could also be applied to the social world. Bayes supplied an early solution; Price preserved and framed it; Laplace turned the idea into a sustained program.
What changes outside the example
Clinical testing. Sensitivity, specificity, predictive value, specimen selection, and the reference standard all matter. The U.S. Food and Drug Administration’s guidance on diagnostic-test studies recommends reporting paired accuracy measures with confidence intervals and warns that study populations and benchmarks affect interpretation. A screening result can change a probability without settling a diagnosis. Real clinical decisions require the actual test’s validation data and the patient’s circumstances, not the invented numbers in this lesson.
Search and rescue. A search team can begin with a probability map for a missing vessel, then lower the probability assigned to a region after searching it without success and redistribute probability elsewhere. The Society for Industrial and Applied Mathematics describes Bayesian search theory as the analytic core of the U.S. Coast Guard’s Search and Rescue Optimal Planning System. A failed search does not prove an area is empty because detection is imperfect—the same conditional-probability reversal appears in a different uniform.
Classification systems. Spam filters and other probabilistic classifiers combine an initial rate with evidence from features. A rare category can still attract many false alarms when a system processes an enormous unaffected population. Modern systems may be much more complicated than the two-branch calculation above, but calibration still asks whether a reported probability matches observed frequencies.
One idea to remember
A test result cannot be interpreted from sensitivity alone. Bayes’ theorem counts both paths to the observed result, and the larger population can make a small false positive rate dominate.
For another lesson about changing probabilities, revisit Markov chains and their long-run behavior. A useful next step is to replace one positive result with a sequence of independent results and ask when multiplying evidence is justified.
Sources
- Thomas Bayes and Richard Price, “An Essay towards Solving a Problem in the Doctrine of Chances”, Philosophical Transactions of the Royal Society of London 53 (1763), 370–418; public-domain scan.
- “Richard Price”, Stanford Encyclopedia of Philosophy, on Price’s religious, political, actuarial, and philosophical work.
- “Laplace, Pierre-Simon Marquis de”, Encyclopedia of Mathematics, on inverse probability and population statistics.
- Stephen M. Stigler, “Laplace’s 1774 Memoir on Inverse Probability”, Statistical Science 1, no. 3 (1986), 359–363.
- Jacob Shreffler and Martin R. Huecker, “Diagnostic Testing Accuracy: Sensitivity, Specificity, Predictive Values and Likelihood Ratios”, StatPearls, updated March 6, 2023.
- U.S. Food and Drug Administration, Statistical Guidance on Reporting Results from Studies Evaluating Diagnostic Tests, 2007.
- J. Van Gurley and Lawrence D. Stone, “Bayesian Search for Missing Aircraft, Ships, and People”, SIAM News, November 1, 2016.