One-Way ANOVA
Comparing Multiple Means
Learn how to test whether three or more group means differ using the \( F \)-statistic, variance decomposition, and the logic behind Analysis of Variance.
Why Not Just Use Multiple \( t \)-Tests?
When comparing three or more groups, running all pairwise \( t \)-tests inflates the probability of a Type I error. With \( k = 4 \) groups you need \( \binom{4}{2} = 6 \) tests, and the overall error rate grows rapidly.
What Is One-Way ANOVA?
Analysis of Variance (ANOVA) tests whether the means of three or more independent groups are equal. Despite the name, it works by comparing variances: variance between groups versus variance within groups.
Visual Intuition: Between vs. Within
The Hypotheses
All group means are equal.
Key Assumptions
Variance Decomposition
ANOVA partitions total variation into two components. The fundamental identity:
Total deviation from grand mean
Between-group (explained)
Within-group (unexplained)
The \( F \)-Statistic
We convert sums of squares into mean squares by dividing by their degrees of freedom, then form a ratio:
Between-group mean square, df = \( k-1 \)
Within-group mean square, df = \( N-k \)
The \( F \)-Distribution
\( t \)-Test vs. ANOVA
| Two-Sample \( t \)-Test | One-Way ANOVA | |
|---|---|---|
| Groups compared | Exactly 2 | \( k \geq 2 \) (typically 3+) |
| Test statistic | \( t \) | \( F \) |
| Relationship | When \( k = 2 \): \( F = t^2 \) | |
| Type I error control | Single comparison | Familywise at \( \alpha \) |
| Identifies which differ? | Yes (only 2 groups) | No: need post-hoc tests |
The ANOVA Table
| Source | SS | df | MS | F |
|---|---|---|---|---|
| Between | SSB | \( k - 1 \) | \( \dfrac{SSB}{k-1} \) | \( \dfrac{MSB}{MSW} \) |
| Within | SSW | \( N - k \) | \( \dfrac{SSW}{N-k} \) | |
| Total | SST | \( N - 1 \) |
Step-by-Step Procedure
Example: Ad Campaign Sales
A company tests three advertising strategies on 15 stores (5 per strategy). Weekly sales (in thousands):
| Strategy A | Strategy B | Strategy C |
|---|---|---|
| 12 | 18 | 14 |
| 14 | 20 | 16 |
| 11 | 17 | 13 |
| 13 | 21 | 15 |
| 10 | 19 | 12 |
Computing SSB and SSW
Building the ANOVA Table
| Source | SS | df | MS | F |
|---|---|---|---|---|
| Between | 130 | 2 | 65 | 26.0 |
| Within | 30 | 12 | 2.5 | |
| Total | 160 | 14 |
Common Mistakes
Question 1 of 5
In a one-way ANOVA with 4 groups and 40 total observations, what are the degrees of freedom for the between-group and within-group sources?
Question 2 of 5
An ANOVA produces \( SSB = 200 \) and \( SSW = 600 \) with \( k = 3 \) groups and \( N = 30 \) observations. What is the \( F \)-statistic?
Question 3 of 5
Which of the following is not an assumption of one-way ANOVA?
Question 4 of 5
A researcher obtains \( F = 5.12 \) with a p-value of 0.012 at \( \alpha = 0.05 \). What is the correct conclusion?
Question 5 of 5
If \( SSB = 130 \), \( SSW = 30 \), and \( SST = 160 \), what is the value of \( \eta^2 \) (eta-squared) and how should it be interpreted?