Bayes' theorem: watch it solved step by step

How likely is a positive test to be real? A table of 100,000 people, then the formula, then what it means. Level: A-level. Type any problem of this kind and the Lab works it out and animates every move, with a plain-words explanation of why.

Worked example: 5% prior, 99% sensitivity, 95% specificity

  1. The question. A test is not perfect. We know how common the condition is (prior), how often the test catches it (sensitivity) and how often it correctly clears a healthy person (specificity). We want: given a positive test, how likely is it that the person really has it?
  2. Picture 100,000 people. Probabilities are easier as counts. Take a crowd of 100,000 and split it up using each percentage.
  3. Among the positive tests. Everyone who tests positive is either a true positive or a false positive. The chance a positive is real is the true positives out of all positives.
  4. Bayes' theorem says the same. The table is just the formula in disguise: prior times likelihood, over everything that could produce a positive.
  5. What it means. A positive result here is strong evidence: about 51% chance of really having it.

Answer: 51.03% (99/194)

Practise bayes' theorem with problems the Lab marks for you.

Loading SumClash…