The prior, doing visible work

The base rate was always Bayes

The screening arithmetic everybody finds counter-intuitive is a posterior update with a prior of one in a thousand. Naming it that way turns a famous puzzle into an instance of a rule, and makes the sequential version obvious.

Worth reading first: What a positive test is worth · What a prior is worth.

The screening result — that a positive test for a one-in-a-thousand condition is right 1.8% of the time — is normally taught as a paradox about intuition. It is not a paradox. It is a posterior, computed from a prior of 0.001 and a likelihood, and calling it that makes several things fall out at once.

What a positive test means, sensitivity 90%, specificity 95%At a prevalence of one in a thousand, 98 of every hundred positives are false. At one in 10, 33 are. The test has not changed.00.2500.5000.7501how common the condition ischance a positive result is true1 in 10,0001 in 1,0001 in 1001 in 101 in 11.8%66.7%one test, every prevalencethe base rate outweighs the test
Fig. 1 The predictive value of a positive result against the base rate. The curve is a posterior and the base rate is the prior.

The same three quantities

Set the two vocabularies side by side.

The prevalence is the prior: what is believed about this person before the test. The test characteristics — sensitivity and specificity — are the likelihood: how probable this result is under each hypothesis. The positive predictive value is the posterior: what is believed after.

That is not an analogy. It is the same computation with different words, and the screening arithmetic in the earlier essay is Bayes’ rule with the terms rearranged into a table of a thousand people.

Two things follow immediately, and both are hard to see in the table form.

The base rate is a prior, so it has the properties priors have. It can be wrong, it can be unknown, and it dominates when the likelihood is weak — which is exactly the reported behaviour of the screening result.

And the “paradox” is that people use a flat prior. Asked what a positive test means, most people answer with the test’s accuracy, which is the answer if the prior odds are even. The intuition is not absent; it is a Bayesian calculation performed with the wrong prior, and the wrongness is enormous — 1:1 against a true 1:999.

The odds form, which is where it becomes portable

The version worth carrying is multiplicative. In odds:

posterior odds  =  prior odds×likelihood ratio\text{posterior odds} \;=\; \text{prior odds} \times \text{likelihood ratio}

The likelihood ratio for a positive result is sensitivity over one-minus-specificity. For a test with 90% sensitivity and 95% specificity that is 0.9 / 0.05 = 18.

So a positive result multiplies the odds by eighteen, whatever they were. Starting from 1:999, the posterior odds are 18:999, which is about 1.8%. Starting from even odds, they are 18:1, which is 95%.

The same test, the same result, two answers three orders of magnitude apart — and the multiplier is a property of the test alone.

That is the sentence worth memorising, because it separates the two contributions cleanly. A test contributes a fixed multiplier. What the result is worth depends on where the multiplication starts.

A thousand people, a condition one in 100 has, a test that is 90% and 95%. 9 people have it and test positive. 50 do not have it and test positive anyway. So of the 59 positive results, 15% are right — and that is with a test most people would call accurate.
Fig. 2 The same computation as a thousand people, which is the form that makes the counts concrete.

The prior and the test, on one scale

Odds turn a product into a sum, and the sum is where the sizes become comparable.

On the log-odds scale, the test contributes log18\log 18, which is 2.89, and a prevalence of one in a thousand contributes log(1/999)\log(1/999), which is −6.91.

The prior is worth two and a half tests. That single comparison is the whole of the screening result: a test contributing 2.89 against a prior contributing −6.91 leaves −4.02, which is odds of 0.018 and a posterior of 1.8%.

Which also says how many tests it would take. Two independent positives give 2×2.896.91=1.132 \times 2.89 - 6.91 = -1.13, odds of 0.32 and a posterior of 24%. Three give +1.76+1.76, odds of 5.8 and a posterior of 85%.

Two positives take a one-in-a-thousand prior to a quarter and three take it to five sixths. That is the screening sequence, arrived at by addition rather than by rebuilding the table of a thousand people three times.

The independence in that calculation is the assumption to watch, and it is usually false for two tests of the same kind: whatever made the first test read positive on a healthy person — an unusual physiology, a cross-reacting substance — is still there for the second. Two different kinds of test come much closer to adding their logarithms, which is the real reason a confirmatory test is a different assay rather than a repeat.

Why the second test works

The sequential version follows directly from the odds form and is the part the table form obscures.

A second independent test multiplies again. Starting at 1:999 and applying the eighteen-fold multiplier twice gives odds of 324:999, or about 24.5%. A third gives 85.4%.

Nothing about the test improved. What changed is the prior each application starts from: the first test moves the person from a 0.1% group to a 1.8% group, and the second test is being applied to a population where the condition is nearly twenty times commoner.

This is why screening programmes are built as sequences, and it is why the sequence works despite each individual test being nearly worthless on the general population.

It is also where the arithmetic has a load-bearing assumption. Multiplying likelihood ratios requires the tests to be conditionally independent given the true state, and two tests for the same condition often share a failure mode — the same protein, the same reader, the same confounding condition. Where they do, the second multiplier is smaller than its nominal value, and in the limiting case where the second test always agrees with the first it contributes a multiplier of one while feeling like confirmation.

Hence the practice of confirming with a different modality. The point is not that the second test is better; it is that its errors are uncorrelated, which is the only condition under which the multiplication is legitimate.

What the Bayesian framing adds

The earlier essay computed all of this correctly without mentioning priors. So it is fair to ask what naming it buys, and there are three things.

The sequence becomes obvious rather than clever. In table form, working out what two positive tests mean requires rebuilding the table with new numbers. In odds form it is multiplication, and the answer for k positives is the prior odds times the multiplier to the k.

The unknown-prevalence case becomes statable. When the base rate is not known — a new condition, an unrepresentative clinic, a screening programme in a population it was not validated on — the frequentist framing has nothing to say and the Bayesian framing says exactly what is missing: the prior. And it says what to do, which is to carry the prior through as a range and report the posterior as a range.

And it connects to the rest of the field. The base rate dominating a weak likelihood is the same phenomenon as a heavy prior dominating a small sample, with the prior’s weight playing the role of the prevalence. Two results that looked like separate curiosities are one result.

weakly informative — Beta(2, 2), updated by 5 of 20. The prior is worth 4 observations. With 20 observations the posterior mean is 0.292, against a data proportion of 0.250 and a prior mean of 0.500.
Fig. 3 The same structure in the field’s own notation: a prior, a likelihood, and the posterior between them.

The likelihood ratio is the honest summary of a test

A practical consequence worth stating on its own, because it is the one that could change what gets reported.

Sensitivity and specificity are the conventional pair, and they are awkward: two numbers, both conditional on the truth, neither directly usable without a prevalence. The likelihood ratio is one number, it is the multiplier, and it is what a reader needs.

A test with a likelihood ratio of 18 for a positive result is worth about the same as a test with 90% sensitivity and 95% specificity, and the single number makes comparisons immediate. A test with a likelihood ratio of 3 is nearly useless whatever its sensitivity, and one with a ratio of 200 is decisive from almost any starting point.

It also makes the asymmetry visible. The negative likelihood ratio for the same test is (1 − sensitivity)/specificity = 0.1/0.95 = 0.105, so a negative result divides the odds by about ten. For a rare condition that takes 1:999 to roughly 1:9,500 — a large relative change and almost no practical one, because the odds were already tiny.

So the same test is informative in one direction and nearly pointless in the other, at this prevalence. That asymmetry is invisible in the sensitivity-specificity pair and immediate in the ratios.

What a positive test means, sensitivity 99%, specificity 95%. At a prevalence of one in a thousand, 98 of every hundred positives are false. At one in 10, 31 are. The test has not changed.
Fig. 4 The same test taken to 99% sensitivity, at the same 95% specificity. At one in a thousand a positive is now worth 1.9% rather than 1.8%: the improvement is real, and it does not rescue the positive predictive value, because it is the specificity and the prior that decide it.

Where the prior comes from, which is the hard part

The framing does not make the difficulty disappear, it relocates it, and the relocation is worth being explicit about.

In screening, the prior is a prevalence, and prevalences are estimated from studies with their own sampling problems. A prevalence measured in one population and applied to another is a prior imported from elsewhere, and the transportability question is real: a screening programme validated in a high-risk clinic and deployed to the general population is running with a prior that is too high by an order of magnitude, and every posterior it computes is too confident.

That failure is not detectable from the programme’s own outputs. It looks like a working programme producing positives at the expected rate.

The general form of the problem is the one this field keeps returning to. A prior is an input, it can be wrong, and its wrongness is not something the data can reveal when the data is being interpreted through it. The available defences are the same as everywhere else: state the prior, report the answer under a range of them, and treat the range as part of the result rather than as a sensitivity analysis in an appendix.

What a 95% credible interval covers, n = 20. Computed by summing over all 21 possible counts rather than by simulating them. Jeffreys' prior covers close to 95% across the range; a confident prior centred in the wrong place covers almost nothing where the truth is far from it.
Fig. 5 What a wrong prior does elsewhere in this field, measured. The screening case has the same structure and no coverage curve, because there is only ever one patient.

That last difference is worth ending on. Everywhere else in this field the prior’s cost can be measured by summing over the sample space. For an individual patient there is no sample space to sum over — there is one person and one result — so the prior’s contribution can be computed but never audited by counting.

Which makes stating it the only available protection, and makes the sequence of tests the only available way to stop depending on it.

A thousand people, a condition one in 56 has, a test that is 90% and 95%. 16 people have it and test positive. 49 do not have it and test positive anyway. So of the 65 positive results, 24% are right — and that is with a test most people would call accurate.
Fig. 6 The count, once more, at the base rate a first positive result leaves behind — one in 56 rather than one in a thousand. Sixteen of the thousand have it and test positive, forty-nine do not and test positive anyway, and the second test is right about a quarter of the time, which is the same 24.5% the odds form gave for two positives. The arithmetic never changed; only the prior it started from.

The same structure outside medicine

The screening arithmetic is taught with a disease, and the structure is general. Three places it appears, all with the same prior-times-multiplier form and the same failure mode.

A test for a rare fault. An automated check that flags 1% of good units and catches 90% of bad ones, applied to a line where 1 in 500 units is defective, has a likelihood ratio of 90 and prior odds of 1:499 — so a flag is right about 15% of the time. The check is excellent and most flags are false, which is the same sentence as the medical case and is usually met with the same disbelief.

A rule that identifies fraud. A detector flagging suspicious transactions faces prior odds set by how rare fraud is, which is very rare. A detector with a likelihood ratio of 1,000 against prior odds of 1:100,000 still produces a posterior of about 1%, and the operational consequence is that the flagged population is overwhelmingly innocent.

An unusual result taken as evidence of a mechanism. A finding that would be surprising under the null is not thereby evidence for a specific alternative, because the likelihood ratio requires a probability under the alternative too. This is the point where the odds form makes contact with what a p-value does not say: a small p-value bounds one of the two terms and says nothing about the other, and the prior is missing entirely.

In every case the corrective is the same and it is arithmetic rather than exhortation. Write the prior odds, multiply by the likelihood ratio, read the answer. The step people skip is the first, and skipping it amounts to assuming even odds.

Why the multiplier is the part worth reporting

A closing recommendation with some force behind it.

Sensitivity and specificity are two numbers, both conditioned on the truth, and neither can be used without a prevalence. Nobody carries them correctly and nobody combines them correctly in their head.

The likelihood ratio is one number, it is the multiplier, and it is directly interpretable: a positive result at a ratio of 18 multiplies the odds by 18, and that statement is complete. It makes tests comparable at a glance, it makes the sequential case a product, and it makes the asymmetry between a positive and a negative result visible — the same test that multiplies by 18 on a positive divides by about 10 on a negative, which for a rare condition is a large relative change and almost no practical one.

The reason this has not happened is not that the ratio is hard. It is that sensitivity and specificity are what validation studies estimate, and the reporting convention followed the estimation convention rather than the use. Converting is a division, and the whole argument of this field is that the converted form is the one that answers the question anybody actually has.

What a positive test means, sensitivity 90%, specificity 95%. At a prevalence of one in a thousand, 98 of every hundred positives are false. At one in 5, 18 are. The test has not changed.
Fig. 7 The same test on a condition that is genuinely common: the second mark has moved from one in ten to one in five. The prior has moved and the test has not, and a positive is worth 81.8% rather than 66.7%.

What the reframing does not fix

Two limits, since the essay has been enthusiastic about the odds form.

It does not supply the prior. Everything above is a machine for turning a prior into a posterior, and the hard question in most applications is what the prior is. In screening it is a prevalence, and prevalences are estimated in one population and applied to another; a programme validated in a high-risk clinic and deployed to the general public is running with a prior too high by an order of magnitude, and every posterior it produces is overconfident in the same direction. Nothing in its own output reveals that.

And it does not make a single result auditable. Everywhere else in this field a prior’s cost can be measured by summing over the sample space and counting how often the resulting interval covers. For one patient with one result there is no sample space — there is a person, a test, and an answer — so the prior’s contribution can be computed and never checked against an outcome.

That asymmetry is the reason the sequential design matters so much in practice. A second independent test does not just raise the posterior; it reduces how much of the final answer came from the prior at all. By the third positive the prior odds have been multiplied by nearly six thousand, and the conclusion is being carried by the tests rather than by the prevalence estimate.

Reducing dependence on an input that cannot be audited is a better defence than getting the input right, because the first is verifiable and the second is a hope. That principle is not specific to screening, and it is the most transferable thing in this essay.

The sentence the field turns on

Both essays about base rates now reduce to the same statement, and it is worth putting plainly.

A test contributes a fixed multiplier to the odds. What a result is worth depends on where the multiplication starts. The multiplier is a property of the instrument and is usually reported; the starting point is a property of the situation and is usually not.

Every version of the base-rate error — in medicine, in fraud detection, in quality control, in reading a p-value as the probability that a hypothesis is false — is the same omission: using the multiplier and assuming the starting point was even.

That framing is why this essay sits in the Bayesian field rather than beside the original base-rate essay in the paradoxes. As a paradox it is a curiosity about human reasoning. As a posterior it is an instance of the rule the whole field runs on, and the fix is not to be more careful — it is to write down the prior odds before multiplying.

Written down, the arithmetic is a multiplication that a reader can do in the margin. Left unwritten, it is the most reliably counter-intuitive result in the subject, and it stays that way however many times the table of a thousand people is redrawn.

Why the table of a thousand people still earns its place

A concession, since this essay has argued for replacing a picture with an equation.

The thousand-people table is the best available device for making the result believed. The odds form makes it computable, transferable and sequential, and it does not make it feel true. Somebody meeting the 1.8% for the first time needs to see the ninety-nine true positives sitting beside the four thousand nine hundred and ninety-five false ones, because the disbelief is about magnitude and only counting fixes that.

So the two forms do different jobs and both are needed. The table converts disbelief into acceptance. The odds form converts acceptance into a method that survives contact with a second test, an unknown prevalence, or a problem that is not about medicine.

The failure is teaching only the first, which leaves a reader convinced of one striking number and unable to compute the next one.

What links here

Computed from the collection, not written here: the essays that point at this one.

Shares its objects with

Essays that name at least two of the same things, and that neither author linked.

Named objects

A flat tag is an object no other essay names yet.

Base rateThe Bayes factorOdds formp-valuePositive predictive valuePosteriorPredictive valuePriorScreeningSequential testing