Bayes' Theorem

Probability
rule

Also known as: Bayes rule, posterior probability

Grade 9-12

View on concept map

Bayes' theorem gives the posterior probability of a hypothesis given evidence: P(H|E) = \frac{P(E|H) \cdot P(H)}{P(E)}. Bayes' theorem is the foundation of modern probabilistic reasoning, powering spam filters, medical diagnostics, and machine learning.

Definition

Bayes' theorem gives the posterior probability of a hypothesis given evidence: P(H|E) = \frac{P(E|H) \cdot P(H)}{P(E)}.

๐Ÿ’ก Intuition

Start with a prior belief, then reweight it by how likely the evidence is under each hypothesis.

๐ŸŽฏ Core Idea

Posterior equals prior times likelihood, normalized by evidence.

Example

A disease test is 99% accurate; 1% of people have the disease. If you test positive, P(\text{disease}|+) \approx 50\% โ€” not 99%, because the disease is rare.

Formula

P(Amid B)= rac{P(Bmid A)P(A)}{P(B)}

Notation

P(A) prior, P(Bmid A) likelihood, P(Amid B) posterior.

๐ŸŒŸ Why It Matters

Bayes' theorem is the foundation of modern probabilistic reasoning, powering spam filters, medical diagnostics, and machine learning. It teaches us how to rationally update our beliefs when we receive new evidence, which is critical in fields from epidemiology to courtroom forensics.

๐Ÿ’ญ Hint When Stuck

When you need to update a probability after new evidence, use Bayes' theorem. First, identify the prior probability P(A) and the likelihood P(B|A). Then compute the total probability of the evidence P(B) = P(B|A)P(A) + P(B|A^c)P(A^c). Finally, apply the formula: P(A|B) = P(B|A) \cdot P(A) / P(B).

Formal View

For events A and B with P(B) > 0: P(A|B) = \frac{P(B|A) \cdot P(A)}{P(B)} where P(B) = P(B|A)P(A) + P(B|A^c)P(A^c) by the law of total probability.

๐Ÿšง Common Stuck Point

The base rate (prior probability P(H)) is the most commonly neglected factor โ€” ignoring it leads to the base-rate fallacy and wildly overconfident conclusions.

โš ๏ธ Common Mistakes

  • Confusing P(A|B) with P(B|A) โ€” the probability of having a disease given a positive test is NOT the same as the probability of testing positive given the disease
  • Forgetting to compute the total probability P(B) using the law of total probability, which accounts for both P(B|A) and P(B|A^c)
  • Ignoring the base rate (prior probability) โ€” a rare disease with a 99% accurate test still yields many false positives when the prior is very low

Frequently Asked Questions

What is Bayes' Theorem in Math?

Bayes' theorem gives the posterior probability of a hypothesis given evidence: P(H|E) = \frac{P(E|H) \cdot P(H)}{P(E)}.

Why is Bayes' Theorem important?

Bayes' theorem is the foundation of modern probabilistic reasoning, powering spam filters, medical diagnostics, and machine learning. It teaches us how to rationally update our beliefs when we receive new evidence, which is critical in fields from epidemiology to courtroom forensics.

What do students usually get wrong about Bayes' Theorem?

The base rate (prior probability P(H)) is the most commonly neglected factor โ€” ignoring it leads to the base-rate fallacy and wildly overconfident conclusions.

What should I learn before Bayes' Theorem?

Before studying Bayes' Theorem, you should understand: conditional probability, probability, sample space.

How Bayes' Theorem Connects to Other Ideas

To understand bayes' theorem, you should first be comfortable with conditional probability, probability and sample space.