Statistics 9: Conditional Probability & Bayes' Theorem

Conditional probability formula, dependent events, multiplication rule, Bayes' theorem with solved factory example, total probability

1. What is Conditional Probability?

Conditional Probability means: probability of an event occurring given that another event has already occurred.

The keyword is: "Given that" or "Knowing that"

Example: A card is drawn. You are told the card is red. What is the probability that it is a king?
This is different from ordinary probability β€” we already know some information (it's red), which changes the calculation.

Formula of Conditional Probability

P(A|B) = P(A ∩ B) / P(B)

SymbolMeaning
P(A|B)Probability of A, given B has already occurred
P(A ∩ B)Probability that both A and B occur
P(B)Probability of B (the given condition)

Card Example: A = Card is King | B = Card is Red
Red cards = 26 | Red Kings = 2
P(King | Red) = 2/26 = 1/13 βœ…


2. Why Conditional Probability Matters

SituationP(King)
No information given4/52 = 1/13
Given card is red2/26 = 1/13
Given card is face card4/12 = 1/3

Additional information can dramatically change probability.

Example 2 β€” Bag with 3 Red + 2 Blue balls:
Given the selected ball is not blue β†’ Only red balls remain.
P(Red | Not Blue) = 1 (certain event)


3. Dependent Events

Events are dependent if occurrence of one affects the probability of the other.

Example: Drawing cards without replacement β€” once an ace is removed, the probability of drawing another ace changes.

Independent vs Dependent

IndependentDependent
One event doesn't affect anotherOne event affects the other
Coin tosses, Dice throwsCard drawing without replacement
With replacementWithout replacement
P(A|B) = P(A)P(A|B) β‰  P(A)

4. Multiplication Rule for Dependent Events

General Formula: P(A ∩ B) = P(A) Γ— P(B|A)

Exam Trick: Whenever you see "without replacement" β†’ think Dependent Events β†’ use conditional probability.

Example β€” Bag: 3 Red, 2 Blue. Draw two red balls successively without replacement.

DrawCalculationResult
First Red3 red out of 5 totalP(R₁) = 3/5
Second Red (given first was red)2 red left out of 4 totalP(Rβ‚‚|R₁) = 2/4 = 1/2

P(R₁ ∩ Rβ‚‚) = 3/5 Γ— 1/2 = 3/10 βœ…


5. Conditional Probability Shortcut

When the sample space shrinks, use:

P = Desired outcomes / Remaining possible outcomes

Example β€” Given card is a face card, find P(King).
Face cards: Jack=4, Queen=4, King=4 β†’ Total = 12 | Kings = 4
P(King | Face) = 4/12 = 1/3


6. Bayes' Theorem

Bayes' theorem reverses probabilities β€” when you know P(B|A) but need to find P(A|B).

Idea: Probability of Cause given Evidence.

Formula: P(A|B) = P(B|A) Γ— P(A) / P(B)

TermMeaning
P(A|B)Posterior β€” probability of cause A given evidence B
P(B|A)Likelihood β€” probability of evidence given cause
P(A)Prior β€” initial probability of cause
P(B)Total probability of evidence

Real-world use: A disease test is positive β†’ What is the probability the person actually has the disease? That is a Bayes problem.

Solved Factory Example

Problem: Machine A produces 60% of items, Machine B produces 40%. Defective rates: A β†’ 2%, B β†’ 5%. A defective item is found. Find probability it came from Machine B.

Step 1 β€” Define events:

EventProbability
P(A) β€” produced by Machine A0.6
P(B) β€” produced by Machine B0.4
P(D|A) β€” defective given Machine A0.02
P(D|B) β€” defective given Machine B0.05

Step 2 β€” Apply Bayes:

P(B|D) = P(D|B) Γ— P(B) / [P(D|A)Γ—P(A) + P(D|B)Γ—P(B)]

= (0.05 Γ— 0.4) / [(0.02 Γ— 0.6) + (0.05 Γ— 0.4)]

= 0.020 / [0.012 + 0.020]

= 0.020 / 0.032

= 0.625 = 62.5% βœ…


7. Tree Diagram Method

Very useful for visualizing probability. Example: Two coin tosses.

PathOutcomeProbability
H β†’ HHH1/2 Γ— 1/2 = 1/4
H β†’ THT1/2 Γ— 1/2 = 1/4
T β†’ HTH1/2 Γ— 1/2 = 1/4
T β†’ TTT1/2 Γ— 1/2 = 1/4

Total = 4/4 = 1 βœ… (probabilities always sum to 1)


8. Total Probability Theorem

Used inside Bayes problems to find P(B).

Formula: P(B) = P(B|A₁)P(A₁) + P(B|Aβ‚‚)P(Aβ‚‚) + Β·Β·Β·

From the factory example:
P(D) = P(D|A)Γ—P(A) + P(D|B)Γ—P(B) = (0.02Γ—0.6) + (0.05Γ—0.4) = 0.012 + 0.020 = 0.032

Bayes' Theorem Keywords

Whenever a question contains these words, think Bayes:

  • "Given" / "Knowing that"
  • "Test result" / "Defective item"
  • "Selected from machine / factory"
  • "Probability it came from…"
  • "Update probability"

Exam MCQs

  • Conditional probability means? β†’ Probability under a given condition
  • Drawing cards without replacement creates? β†’ Dependent events
  • Which theorem is used to reverse probabilities? β†’ Bayes' Theorem
  • If events are independent, P(A|B) = ? β†’ P(A)
  • Bayes theorem is mainly used for? β†’ Updating probabilities

Common Exam Traps:

TrapRule
Independent eventsP(A|B) = P(A) β€” condition doesn't matter
"Without replacement"β†’ Dependent events
"With replacement"β†’ Independent events
Bayes reversesFrom P(B|A) β†’ finds P(A|B)

Quick Revision Sheet

Formula / ConceptDetail
Conditional ProbabilityP(A|B) = P(A ∩ B) / P(B)
Multiplication Rule (Dependent)P(A ∩ B) = P(A) Γ— P(B|A)
Independent EventsP(A|B) = P(A)
Bayes' TheoremP(A|B) = P(B|A) Γ— P(A) / P(B)
Total ProbabilityP(B) = Ξ£ P(B|Aα΅’) Γ— P(Aα΅’)
Without replacement→ Dependent → use conditional probability
With replacementβ†’ Independent β†’ P(A ∩ B) = P(A) Γ— P(B)