ANOVA — Definition, Formula & Examples
ANOVA (analysis of variance) is a hypothesis test that checks whether the means of three or more groups are all equal. It does this by comparing how spread out the group means are with how spread out the data are inside each group.
One-way ANOVA tests against : at least one differs. The test statistic is . If is true, follows an F-distribution with and degrees of freedom. The test assumes independent random samples, approximately normal populations, and equal population standard deviations.
Key Formula
Where:
- = number of groups
- = total number of observations across all groups
- = sample size, mean, and standard deviation of group i
- = grand mean of all N observations
- = mean square between groups (variation among group means)
- = mean square error (variation within groups)
Worked Example
Problem: Three fertilizers are each tested on 3 plants. The growth values (cm) are A: 2, 3, 4; B: 4, 5, 6; C: 6, 7, 8. Test whether the mean growth is the same for all three fertilizers.
Step 1: Find each group mean and the grand mean. Here and .
Step 2: Compute the between-group and within-group mean squares. Each group's squared deviations from its own mean sum to .
Step 3: Compute and find the p-value from the F-distribution with 2 and 6 degrees of freedom.
Answer: with p-value . At , reject . There is convincing evidence that at least one fertilizer has a different mean growth.
Why It Matters
Running several two-sample t-tests on the same groups raises the chance of a false positive. ANOVA avoids this by testing all the means at once. It is not on the current AP Statistics exam outline, but it is standard in college statistics, psychology research, and agricultural and medical experiments.
Common Mistakes
Mistake: Concluding that all the group means are different after rejecting .
Correction: A small p-value only tells you that at least one mean differs. To find which pairs differ, you need a follow-up procedure such as Tukey's method.
