Chi-Squared Goodness of Fit for Uniform, Binomial and Poisson Models | Edexcel IAL Maths notes

Free preview: Chi-Squared Goodness of Fit for Uniform, Binomial and Poisson Models

Does a Model Fit the Data?

Unit S3 (WST03): Statistics 3

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:

Score123456
Observed O152218261722
Expected E202020202020
  • If the die is fair, each score has probability 16, so we expect 120×16=20 of each.
  • A goodness of fit test asks whether the observed counts are close enough to the expected counts from a model.
  • H0: the model fits (the die is fair). H1: the model does not fit.
  • The test statistic measures how far the observed counts are from the expected ones: X2=∑(O−E)2E, compared with the upper tail of χν2.
  • Same rule: every E must be at least 5, or merge cells.

Degrees of freedom

ν=(number of cells after merging)−1−(number of parameters estimated from the data)

  • 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.

Diagram: These are the 5 expected frequencies for the goals example, from Po(1.91).

What the picture shows

  • These are the 5 expected frequencies for the goals example (page 2), from Po(1.91).
  • Three cells are free. The total of 100 fixes one more, and using the data to estimate λ fixes another.
  • So ν=5−1−1=3.
  • If λ is given in the question, it is not estimated, so do not subtract it: ν=4.

Method: goodness of fit

  1. Hypotheses: H0: the model fits; H1: it doesn't. Name the model.
  2. Estimate any parameter the question doesn't give.
  3. Expected frequencies E = total × model probability. Make the last cell take the whole tail.
  4. Merge any cell with E below 5.
  5. X², then ν = cells − 1 − parameters estimated.
  6. Compare with the upper critical value and conclude.

👀 Watch me do it: is the die fair? Test at 5%

What I writeWhy I do it
H0: the die is fair (discrete uniform). H1: it is notStep 1.
E = 20 for every scoreStep 3. All at least 5, so no merging.
X2=25+4+4+36+9+420=8220=4.10The squared gaps are 25, 4, 4, 36, 9, 4, all over the same E.
6 cells, nothing estimated: ν=6−1=5. χ52(0.05)=11.070Step 5.
4.10<11.070: do not reject H0No evidence at 5% that the die is biased.

Where the critical value comes from

  • If H0 is true and every expected frequency is at least 5, X2 approximately follows a χ2 distribution with ν degrees of freedom.
  • Read the critical value from the booklet's table of percentage points of the χ2 distribution. χ52(0.05)=11.070 means that, when ν=5, X2 is above 11.070 with probability 0.05.
  • The test is always upper-tailed: only a big X2 is evidence against the model. Reject H0 when X2 is greater than the critical value.
  • Any expected frequency below 5 must first be combined with a neighbouring cell. You'll see this on page 2.
ν10%5%1%
12.7063.8416.635
24.6055.9919.210
36.2517.81511.345
47.7799.48813.277
59.23611.07015.086

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.

Log in · Subscribe · Start free trial

All notes in S3.3 Goodness of Fit, Contingency Tables and Rank Correlation

  1. Chi-Squared Goodness of Fit for Uniform, Binomial and Poisson Models
  2. Goodness of Fit for Continuous Uniform and Normal Models
  3. Chi-Squared Tests for Independence in Contingency Tables
  4. Spearman's Rank Correlation Coefficient
  5. Hypothesis Tests for Correlation and Association: PMCC or Spearman?

Video

What's inside for this topic

5 teacher notes, 142 practice questions, 40 flashcards, 2 quizzes.

Get the full notes, every practice question, flashcards, quizzes and mock papers.

Start your free 7-day trial

Questions? Chat with us on WhatsApp · Try one live lesson

Next note: Goodness of Fit for Continuous Uniform and Normal Models

Chi-Squared Goodness of Fit for Uniform, Binomial and Poisson Models on other exam boards

All Edexcel IAL Maths topics · A Level Maths