Chi-Squared Goodness of Fit for Uniform, Binomial and Poisson Models | Cambridge A Level Maths notes
Free preview: Chi-Squared Goodness of Fit for Uniform, Binomial and Poisson Models
Does a Model Fit the Data?
9231 Paper 4: Further Probability & Statistics
Watch: 1-minute explainer
Every time you say "goals in a match are Poisson" or "this die is fair", you are using a model. But is the model any good? Real data never match a model exactly. This note gives a test for whether the gaps are small enough to be chance.
Let's start with a die. It is rolled 120 times:
| Score | 1 | 2 | 3 | 4 | 5 | 6 |
|---|---|---|---|---|---|---|
| Observed O | 15 | 22 | 18 | 26 | 17 | 22 |
| Expected E | 20 | 20 | 20 | 20 | 20 | 20 |
- If the die is fair, each score has probability , so we expect of each.
- A goodness of fit test asks whether the observed counts are close enough to the expected counts from a model.
- : the model fits (the die is fair). : the model does not fit.
- Same statistic as for contingency tables: , compared with the upper tail of .
- Same rule: every E must be at least 5, or merge cells.
Degrees of freedom
- Why −1? The expected frequencies are made to add up to the same total as the observed ones, which fixes one cell.
- Why subtract estimated parameters? Each one makes the model bend towards the data, which costs another degree of freedom.

What the picture shows
- These are the 5 expected frequencies for the goals example (page 2), from .
- Three cells are free. The total of 100 fixes one more, and using the data to estimate fixes another.
- So .
- If is given in the question, it is not estimated, so do not subtract it: .
Method: goodness of fit
- Hypotheses: : the model fits; : it doesn't. Name the model.
- Estimate any parameter the question doesn't give.
- Expected frequencies E = total × model probability. Make the last cell take the whole tail.
- Merge any cell with E below 5.
- X², then = cells − 1 − parameters estimated.
- Compare with the upper critical value and conclude.
👀 Watch me do it: is the die fair? Test at 5%
| What I write | Why I do it |
|---|---|
| : the die is fair (discrete uniform). : it is not | Step 1. |
| E = 20 for every score | Step 3. All at least 5, so no merging. |
| The squared gaps are 25, 4, 4, 36, 9, 4, all over the same E. | |
| 6 cells, nothing estimated: . | Step 5. |
| : do not reject | No evidence at 5% that the die is biased. |
Given ratios
- A genetics model predicts types in the ratio 9 : 3 : 3 : 1. The shares add to . With 320 plants, = 180, 60, 60, 20.
- Observed 190, 52, 58, 20 gives , , below 7.815: the model fits.
✏️ YOUR TURN 1
Try this first:
A shop records 150 complaints over the 5 weekdays: Mon 38, Tue 26, Wed 24, Thu 28, Fri 34. Test at the 5% level whether complaints are equally likely on each day.
Answer:
- E = 30 each. Squared gaps 64, 16, 36, 4, 16, total 136.
- .
- , critical value 9.488.
- : do not reject; no evidence that complaints depend on the day.
Unlock the full note: start 7 days free.
Log in or subscribe to read the rest of this note. Members also get the AI tutor, practice quizzes, mock exams and flashcards for this topic.
All notes in χ²-tests (4.3)
- Chi-Squared Tests for Independence in Contingency Tables
- Chi-Squared Goodness of Fit for Uniform, Binomial and Poisson Models
- Goodness of Fit for Geometric and Continuous Models
Video
What's inside for this topic
3 teacher notes, 81 practice questions, 34 flashcards, 2 quizzes.
Get the full notes, every practice question, flashcards, quizzes and mock papers.
Previous note: Chi-Squared Tests for Independence in Contingency Tables Next note: Goodness of Fit for Geometric and Continuous Models