Home › IB Maths AI HL › Questions by topic › Chi-Square Goodness of Fit, Independence and Error Types

IB Maths AI HL · Unit 4: Statistics and Probability

IB Maths AI HL Chi-Square Goodness of Fit, Independence and Error Types Questions

Exam-style IB Maths AI HL chi-square goodness of fit, independence and error types questions with worked solutions. Start with the 3 fully worked examples below — each is solved step by step the way an IB examiner expects — then try the practice questions and check your working against the mark scheme.

Practise Chi-Square Goodness of Fit, Independence and Error Types questions → AI HL formula booklet

What you need to know

HL AI extends SL AI's chi-squared with confidence intervals for the population mean. Practise the t-distribution CDF on your GDC. Chi-squared test and confidence intervals overview →

One-sample and two-sample t-tests when the population variance is unknown. HL AI expects the null, alternative, test statistic, and p-value each stated explicitly. Hypothesis testing — t-test and chi-squared overview →

What's examined in AI HL chi-square goodness of fit, independence and error types

The question bank covers these chi-square goodness of fit, independence and error types question types (number of questions in brackets):

Key formulas

Chi-squared test statistic
\(\chi^2_{\text{calc}} = \sum \dfrac{(f_o - f_e)^2}{f_e}\)

In the same notation as the IB formula booklet. All AI HL formulas →

Chi-Square Goodness of Fit, Independence and Error Types worked examples

Worked example 1: Calculating Expected Frequencies and Degrees of Freedom · easy

A researcher conducts a $\chi^2$ test for independence at the $5\%$ significance level to determine if there is an association between a person's gender (Male, Female) and their preferred professional field (Engineering, Medicine, Law). The survey collected responses from $220$ individuals. In the sample, there were $110$ Males, and $90$ people in total preferred Engineering. Calculate the expected frequency of Males who prefer Engineering, and state the degrees of freedom for this test.

Solution

1. Identify the formula for expected frequency: $\frac{\text{Row Total} \times \text{Column Total}}{\text{Grand Total}}$.

2. Substitute the known values: $\frac{110 \times 90}{220}$.

3. Calculate the expected frequency: $\frac{9900}{220} =$ $45$.

4. Identify the formula for degrees of freedom in a two-way table: $\text{df} = (\text{rows} - 1) \times (\text{columns} - 1)$.

5. Evaluate the degrees of freedom: $(2 - 1) \times (3 - 1) = 1 \times 2 =$ $2$.

Examiner tip: Always show your unrounded expected frequencies in your working if asked to construct an expected frequency table, as prematurely rounding these values can throw off your final $\chi^2$ statistic.

Worked example 2: Performing a $\chi^2$ Goodness of Fit Test · medium

A $6$-sided die is rolled $120$ times. The observed frequencies for the scores $1$ to $6$ are $27, 12, 16, 25, 26,$ and $14$, respectively. Conduct a $\chi^2$ goodness of fit test at the $5\%$ significance level to determine if the die is fair. State your null hypothesis, the $p$-value, and your conclusion.

Solution

1. State the null hypothesis ($H_0$): The die is fair (the outcomes follow a uniform distribution).

2. Calculate the expected frequency for each face if the die is fair: $\frac{120}{6} = 20$.

3. Enter the observed list $\{27, 12, 16, 25, 26, 14\}$ and the expected list $\{20, 20, 20, 20, 20, 20\}$ into the GDC.

4. Execute the $\chi^2$ Goodness of Fit test on the GDC with $\text{df} = 6 - 1 = 5$.

5. Extract the $p$-value from the GDC output: $p = 0.0458$ (to 3 s.f.).

6. Compare the $p$-value to the significance level: $0.0458 < 0.05$.

7. Conclude: Since the $p$-value is less than $0.05$, we reject $H_0$. There is sufficient evidence to suggest the die is biased.

Examiner tip: To score the final reasoning and accuracy marks in hypothesis testing, you must explicitly show the comparison of your $p$-value against the given significance level (e.g., $0.0458 < 0.05$) before stating your conclusion in context.

Worked example 3: Calculating the Probability of a Type I Error · hard

A factory machine produces bolts. The length of the bolts, $X$, is modelled by a normal distribution. The machine is working correctly if the mean length is $\mu = 50\text{ mm}$ with a standard deviation $\sigma = 1.2\text{ mm}$ ($H_0$). The machine is shut down for repairs if a randomly selected bolt has a length strictly greater than $52.5\text{ mm}$. Calculate the exact probability of making a Type I error.

Solution

1. Recall the definition of a Type I error: rejecting the null hypothesis $H_0$ when it is actually true.

2. Identify the rejection region from the prompt: $X > 52.5\text{ mm}$.

3. Set up the probability statement assuming $H_0$ is true: $P(X > 52.5 \mid \mu = 50, \sigma = 1.2)$.

4. Use the Normal Cumulative Distribution function on the GDC with lower bound $52.5$, upper bound $10^{99}$, $\mu = 50$, and $\sigma = 1.2$.

5. Evaluate the probability: $0.018610\dots$

6. The probability of a Type I error is $0.0186$ (or $1.86\%$).

Examiner tip: A Type I error ($\alpha$) is calculated entirely using the parameters of the Null Hypothesis ($H_0$), whereas a Type II error ($\beta$) is calculated using the parameters of the Alternative Hypothesis ($H_1$).

Try these IB Maths AI HL chi-square goodness of fit, independence and error types questions

Three questions from the bank, easiest first. Mark schemes and AI marking of your written working are in the practice area.

Question 1 · easy · 4 marks · Paper 1

A researcher conducts a Chi-Square test for independence to see if eye color (Blue, Green, Brown, Hazel) is independent of hair color (Blonde, Brown, Black, Red, Other).
Calculate the exact number of degrees of freedom (\(df\)) for this test.

Attempt it and see the mark scheme →

Question 2 · medium · 6 marks · Paper 1

A geneticist expects a ratio of \(9 : 3 : 3 : 1\) for four phenotypes (A, B, C, D) in a certain plant. She grows \(160\) plants and observes the following: - Phenotype A: \(85\) - Phenotype B: \(34\) - Phenotype C: \(35\) - Phenotype D: \(6\)
Perform a Goodness of Fit test at the \(10\%\) significance level to determine if the plants follow the expected genetic ratio.

Attempt it and see the mark scheme →

Question 3 · hard · 8 marks · Paper 1

A researcher claims that the heights of plants in a greenhouse follow a Normal distribution with \(\mu = 120\) cm and \(\sigma = 15\) cm. He categorizes \(200\) plants into three intervals: - Group 1: \(< 105\) cm - Group 2: \(105\) cm to \(135\) cm - Group 3: \(> 135\) cm
Calculate the expected frequency (\(f_e\)) for each of the three groups, correct to 1 decimal place.

Attempt it and see the mark scheme →

All 20 chi-square goodness of fit, independence and error types questions with mark schemes →

FAQ

How many IB Maths AI HL chi-square goodness of fit, independence and error types questions are there?

There are 20 exam-style chi-square goodness of fit, independence and error types questions in the AI HL question bank (Paper 1: 19 · Paper 2: 1), graded 5 easy, 5 medium, 5 hard, 5 starter. Every question has a full IB-style mark scheme (M, A and R marks).

Is chi-square goodness of fit, independence and error types on Paper 1 or Paper 2?

Both. In the bank, Paper 1: 19 · Paper 2: 1. Practise with your GDC — AI papers expect calculator methods throughout.

Where can I get the mark schemes?

Open the AI HL Unit 4 practice page: every question has a step-by-step IB-style mark scheme, and you can photograph your working for instant AI marking. The worked examples on this page are free.

More AI HL Unit 4 topics

← All IB Maths AI HL topics