STAT 101
M03 · L02
Module 3

Conditional Probability

When we learn something about the world, probability changes. Conditional probability is the mathematics of “given that…”

01 / 13
STAT 101
M03 · L02
Restricting the sample space

What is P(A | B)?

Learning that B occurred restricts our world to outcomes inside B. The conditional probability of A given B is the fraction of B that also belongs to A.

Intuition
P(A | B) = fraction of B’s outcomes that are also in A
02 / 13
STAT 101
M03 · L02
The formal definition

The Formula

Divide the probability of both events occurring by the probability of the conditioning event. Requires P(B) > 0.

Conditional probability
P(A \mid B) = \dfrac{P(A \cap B)}{P(B)}
03 / 13
STAT 101
M03 · L02
Rearranging the definition

Multiplication Rule

Cross-multiply the definition to get the probability of both events occurring as a product of a conditional and a marginal.

Multiplication rule
P(A \cap B) = P(A \mid B) \cdot P(B)
04 / 13
STAT 101
M03 · L02
When information is irrelevant

Statistical Independence

A and B are independent when knowing B gives no information about A. The conditioning makes no difference.

Condition
P(A | B) = P(A)
Equivalent
P(A ∩ B) = P(A)·P(B)
05 / 13
STAT 101
M03 · L02
Common confusion

Independent ≠ Disjoint

  • Disjoint: A ∩ B = ∅ — they cannot both occur
  • Independent: one occurring tells us nothing about the other
  • If A ∩ B = ∅ and P(A), P(B) > 0 → they are dependent
  • Knowing A happened means B definitely did not
06 / 13
STAT 101
M03 · L02
Averaging over a partition

Law of Total Probability

Partition Ω into mutually exclusive, exhaustive cases B1…Bn. Then P(A) is a weighted average of conditional probabilities.

Total probability
P(A) = \sum_{i} P(A \mid B_i)\, P(B_i)
07 / 13
STAT 101
M03 · L02
Inverting the conditioning

Bayes’ Theorem

Turns a likelihood P(B|A) into a posterior P(A|B). Prior × likelihood ÷ evidence.

Bayes’ theorem
P(A \mid B) = \dfrac{P(B \mid A)\, P(A)}{P(B)}
08 / 13
STAT 101
M03 · L02
Visual tool

Tree Diagrams

  • Each branch = one event, labeled with its probability
  • Along a path: multiply probabilities
  • Across paths: add probabilities
  • Entire tree uses multiplication rule at every step
09 / 13
STAT 101
M03 · L02
Factory example

Total Probability at Work

Factory A: 60% of output, 2% defective. Factory B: 40%, 5% defective. Overall defect rate?

Calculation
P(defect) = 0.6×0.02 + 0.4×0.05 = 0.012 + 0.020 = 3.2%
10 / 13
STAT 101
M03 · L02
A costly mistake

P(A|B) ≠ P(B|A)

  • P(positive test | disease) = sensitivity (often high)
  • P(disease | positive test) = depends on prevalence
  • Prosecutor’s fallacy: P(evidence | innocent) ≠ P(innocent | evidence)
  • Bayes’ theorem is the only safe way to invert conditioning
11 / 13
STAT 101
Knowledge Check

Check what stuck

Four questions from this lesson. Answer to see why — the explanation appears whether you were right or wrong. Nothing is scored or saved.

Question 1 of 0
Score 0/0

12 / 13
STAT 101
Summary
Recap

What you learned

Conditional probability, the multiplication rule, independence, the law of total probability, Bayes’ theorem, tree diagrams, and why P(A|B) ≠ P(B|A) — the engine of statistical inference.

13 / 13