Choosing Among the Three Tests

AP Statistics · Unit 3 — Inference for Categorical Data: Proportions

Key takeaway

From the May 2027 exam, the goodness-of-fit test is no longer tested. Only the two chi-square tests for two-way tables remain: homogeneity and independence.

Count the variables and the samples

Homogeneity and independence use identical arithmetic; they differ only in how the data were collected and therefore in how the conclusion is worded. Homogeneity concludes about differences between groups; independence concludes about an association between variables.

Worked example: goodness-of-fit test

A die rolled $120$ times gives faces $1$–$6$ with counts $15,25,18,22,20,20$. Test whether the die is fair.

Solution

Type: one variable (the face of the die), one sample, compared with a uniform distribution ⇒ goodness-of-fit test.

Expected count per face: $\frac{120}{6}=20$ — every cell $\ge5$ ✓.

$$\chi^2=\frac{25}{20}+\frac{25}{20}+\frac{4}{20}+\frac{4}{20}+0+0=\frac{58}{20}=2.9$$

$df=6-1=5$. With $df=5$, the value $\chi^2=2.9$ gives $P\approx0.72$ — very large.

Conclusion: there is not enough evidence that the die is unfair.

Common mistake

The $df$ of a goodness-of-fit test is $k-1$ (the number of categories minus one), not $n-1$. Mixing this up makes the $P$-value completely wrong even if $\chi^2$ is computed correctly.

Key takeaway

One variable, one sample ⇒ goodness-of-fit, $df=k-1$. Several samples ⇒ homogeneity. One sample, two variables ⇒ independence. The last two both have $df=(r-1)(c-1)$.

← Two-Way Tables: The Full Four-Step Test · All AP Statistics lessons · Practice AP Statistics questions (free, instant scoring) · The Chi-Square Family, Small Expected Counts and the Link to z →