MathIsimple
Lesson 5.2: Conditional Probability & Two-Way Tables

Master Conditional Probability & Two-Way Tables

Discover the power of conditional probability! Learn to use two-way tables to analyze relationships between events and understand when events are independent or dependent.

Learning Objectives

Create and interpret two-way tables
Calculate conditional probabilities
Determine if events are independent
Apply probability rules to real situations

Two-Way Tables Basics

What is a Two-Way Table?

• A table that shows the relationship between two categorical variables

• Rows represent one variable, columns represent another

• Each cell shows the count (frequency) of observations

• Totals are shown in margins (row totals, column totals, grand total)

Example 1: Student Survey

Survey: 100 students were asked about their favorite subject and whether they play sports.

MathScienceEnglishTotal
Play Sports15201045
Don't Play Sports25151555
Total403525100

Conditional Probability

Conditional Probability Formula

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

• P(A|B) = "Probability of A given B"

• P(A and B) = "Probability of both A and B occurring"

• P(B) = "Probability of B occurring"

Example 2: Using the Two-Way Table

Question: What is the probability that a student likes Math, given that they play sports?

Step 1: Identify the given condition

Given: Student plays sports (45 students total)

Step 2: Find the intersection

Students who play sports AND like Math = 15

Step 3: Calculate conditional probability

P(Math | Sports) = 15/45 = 1/3 ≈ 0.333

Interpretation: 33.3% of students who play sports like Math

Example 3: Another Conditional Probability

Question: What is the probability that a student plays sports, given that they like Science?

Step 1: Identify the given condition

Given: Student likes Science (35 students total)

Step 2: Find the intersection

Students who like Science AND play sports = 20

Step 3: Calculate conditional probability

P(Sports | Science) = 20/35 = 4/7 ≈ 0.571

Interpretation: 57.1% of students who like Science play sports

Independence of Events

Definition of Independence

Two events A and B are independent if:

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

This means that knowing one event occurred doesn't change the probability of the other event.

Example 4: Testing Independence

Question: Are "liking Math" and "playing sports" independent events?

Step 1: Calculate P(Math)

P(Math) = 40/100 = 0.4

Step 2: Calculate P(Math | Sports)

P(Math | Sports) = 15/45 = 1/3 ≈ 0.333

Step 3: Compare the probabilities

P(Math) = 0.4 ≠ P(Math | Sports) = 0.333

Conclusion: The events are NOT independent

Knowing that a student plays sports changes the probability that they like Math.

Real-World Applications

Example 5: Medical Testing

Scenario: A medical test for a disease has 95% accuracy. In a population where 2% have the disease, what's the probability someone has the disease given a positive test result?

Given Information:

• Disease prevalence: 2%

• Test accuracy: 95%

• False positive rate: 5%

Two-Way Table (per 1000 people):

Has DiseaseNo DiseaseTotal
Positive Test194968
Negative Test1931932
Total209801000

Solution:

P(Disease | Positive Test) = 19/68 ≈ 0.279

Only 27.9% of people with positive test results actually have the disease!

Common Mistakes to Avoid

❌ Mistake 1: Confusing P(A|B) and P(B|A)

P(A|B) ≠ P(B|A). The order matters! P(A|B) means "A given B", not "B given A"

❌ Mistake 2: Using wrong denominator

For P(A|B), use the total for B as the denominator, not the grand total

❌ Mistake 3: Assuming independence

Don't assume events are independent. Always test using P(A|B) = P(A)

Practice Problems

Problem 1:

From the table above, find P(English | Don't Play Sports)

Show Solution

P(English | Don't Play Sports) = 15/55 = 3/11 ≈ 0.273

Problem 2:

Are "liking Science" and "playing sports" independent events?

Show Solution

P(Science) = 35/100 = 0.35

P(Science | Sports) = 20/45 ≈ 0.444

Since 0.35 ≠ 0.444, the events are NOT independent

Problem 3:

Find P(Don't Play Sports | Math)

Show Solution

P(Don't Play Sports | Math) = 25/40 = 5/8 = 0.625

Advanced Probability Concepts

Bayes' Theorem

Formula:

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

Use: Updating probabilities with new information

Law of Total Probability

Formula:

P(A) = Σ P(A|Bᵢ) × P(Bᵢ)

Use: Finding total probability across all scenarios

Real-world Applications

Medical Diagnosis

Disease Testing

False positive/negative rates

Treatment effectiveness and side effects

Quality Control

Manufacturing

Defect detection and prevention

Process optimization and monitoring

Risk Assessment

Insurance

Premium calculation and claims

Investment portfolio management