🎯 The Purpose
The t-test is a statistical method used to determine if there is a significant difference between two means. It acts as a judge, deciding whether differences are real or just a coincidence.
"Are the means of two groups statistically different from each other, or is the difference due to random chance?"
The Question
Is the difference meaningful?
🔍 When to use a t-test
Make sure your data fits these criteria.
Two Groups
Comparing strictly two groups (e.g., Male vs Female, Control vs Exp).
Interval/Ratio
Data must be continuous numbers (scores, height, time), not categories.
Normal Dist.
The data should roughly follow a bell curve shape.
Means
You are comparing averages, not medians or proportions.
🔣 The Logic & Formula
Simplified Concept
- 1 Numerator (Top): How far apart are the group averages? (Signal)
- 2 Denominator (Bottom): How much variation (noise) is inside the groups?
Interactive Simulator
📈 Types of t-tests
Independent Samples t-test
Compares the means of two separate, unrelated groups.
Example: Comparing test scores of Class A (taught by AI) vs. Class B (taught by Human).
❗ Interpreting Results (The p-value)
< 0.05
Significant Difference
Reject the Null Hypothesis.
"The effect is likely real, not just luck."
> 0.05
Not Significant
Fail to Reject the Null Hypothesis.
"The difference could easily happen by chance."
Real World Example
Comparing grammar scores: Class A (AI Tool, Mean=80) vs Class B (No Tool, Mean=74). Since p = 0.02 (which is less than 0.05), the difference is statistically significant. Class A likely benefited from the tool.