Probability and statistics · University

Bayes' theorem

P(A|B) = P(B|A)P(A)P(B)

The idea

How to update your belief when you get new evidence.

The board

  1. 1% of people have a disease. The test catches 99% of the sick but gives 5% false alarms.
  2. Out of 10.000 people: 100 sick → 99 positive. 9.900 healthy → 495 positive.
  3. You tested positive: the chance you're sick is 9999 + 495 ≈ 17\% — not 99%!
  4. P(A|B) = P(B|A) · P(A)P(B).

The most common mistake

Ignoring how rare the event is (the base rate). It's the most common mistake, even among doctors.

The trick

Always calculate with 10.000 imaginary people — Bayes turns into arithmetic.

Problems

With a rare disease, a positive test…

  • doesn't matter
  • is often false
  • is 99% certain
  • is certain
Show the answer

is often false — There are many false alarms.

P(A) in Bayes is called…

  • conditional
  • the prior probability
  • the posterior
  • total
Show the answer

the prior probability — The belief before the evidence.

Take the lesson · exercises and XPFree, no sign-up needed.

You need to know