Back to homeMathematics · 6th Year HL · Change subject
Start for free
6th Year HL · Mathematics
Statistics · Inference

Hypothesis testing

A crisp manufacturer claims that its bags weigh $150$ g; a guidance counsellor at a secondary school in Cork suspects that her 6th Year students spend less time on their phones than the national average. In both cases there is a starting claim and a sample that may, or may not, contradict it. Hypothesis testing is the formal procedure for deciding, using a sample, whether that claim stands or is rejected.

Null and alternative hypotheses

Conceptual diagram comparing the null hypothesis H0 as an equality with the alternative hypothesis H1 in its two-tailed and one-tailed forms. H₀: μ = μ₀ (starting claim) H₁: μ ≠ μ₀ (two-tailed) or μ>μ₀ / μ<μ₀ (one-tailed)
Practice★☆☆Not started
In quality control at a crisp factory, we wish to check whether the mean weight of the packets is really $150$ grams, as stated on the packaging. The population standard…

In quality control at a crisp factory, we wish to check whether the mean weight of the packets is really $150$ grams, as stated on the packaging. The population standard deviation is known to be $\sigma = 5$ grams. If it is suspected that the packets may weigh either more or less than stated:

  1. a) State the hypotheses $H_0$ and $H_1$.
  1. b) If we set a significance level of $\alpha = 0.05$, calculate the critical values $z_{\alpha/2}$ that bound the acceptance region.
Solve

Type I and type II errors

Decision table for a hypothesis test showing the correct decisions and the type I and type II errors according to whether the null hypothesis is true or false. Correct Type II error (β) Type I error (α) Correct H₀ true H₀ false Accept H₀ Reject H₀
Practice★☆☆Not started
Explain in your own words what it means to make a Type I Error in the context of a study attempting to test whether a new study method improves mathematics marks (where…

Explain in your own words what it means to make a Type I Error in the context of a study attempting to test whether a new study method improves mathematics marks (where $H_0$ is that the method yields no improvement).

Solve
Practice★★☆Not started
A new model of running shoes designed to increase performance is being tested. The manufacturer sets the null hypothesis $H_0$: "The mean performance with the new model…

A new model of running shoes designed to increase performance is being tested. The manufacturer sets the null hypothesis $H_0$: "The mean performance with the new model is equal to that of the previous model" against the alternative hypothesis $H_1$: "The mean performance is higher".

Give reasons explaining what making a Type I error and a Type II error would mean in this practical context. Which of the two errors do you think would be more damaging to the company's brand image if discovered later?

Solve
Practice★★★Not started
The Environmental Protection Agency (EPA) conducts periodic checks on discharges from a paper mill into a riverbed. Due to environmental regulations, the mean nitrate…

The Environmental Protection Agency (EPA) conducts periodic checks on discharges from a paper mill into a riverbed. Due to environmental regulations, the mean nitrate concentration must not exceed $\mu_0 = 15\text{ mg/l}$. It is assumed that the measurements follow a normal distribution with a known standard deviation $\sigma = 2\text{ mg/l}$. The administration takes a sample of $n = 16$ independent water samples and sets up the test $H_0: \mu \le 15$ against $H_1: \mu > 15$.

  1. a) Precisely define what it means to commit a Type I error and a Type II error in this specific scenario. Explain in detail the practical and real consequences that each would entail for the paper mill and for the river ecosystem.
  2. b) At the technical committee, a disagreement arises regarding the significance level: the company's legal counsel requests setting $\alpha = 0.01$, while the environmental protection technicians prefer $\alpha = 0.10$. Reason which type of error each party seeks to minimize and which of the two levels provides greater guarantee of immediate intervention in the event of actual pollution.
  3. c) After performing the laboratory analyses of the $n = 16$ samples, a mean concentration of $\bar{x} = 16.1\text{ mg/l}$ is obtained. Calculate the p-value of the test and determine with reasoning what penalty or administrative resolution would be adopted under the company's criterion ($\alpha = 0.01$) and under the environmental criterion ($\alpha = 0.10$). How does this result illustrate that the chosen significance threshold conditions decision-making?
Solve

Test statistic and p-value for a mean

The tables in Formulae and Tables give $P(Z

Practice★☆☆Not started
We are conducting a two-tailed hypothesis test for the mean of a normal population with known $\sigma$. After calculating the test statistic with the data from a sample,…

We are conducting a two-tailed hypothesis test for the mean of a normal population with known $\sigma$. After calculating the test statistic with the data from a sample, we obtain a value of $z_{exp} = 2.15$.

If the critical values for a significance level of $\alpha = 0.05$ are $-1.96$ and $1.96$, reason whether we should accept or reject the null hypothesis.

Solve
Practice★☆☆Not started
The Road Safety Authority (RSA) states that the mean speed on a peri-urban stretch regulated with an educational radar is $\mu = 80\text{ km/h}$, with a known population…

The Road Safety Authority (RSA) states that the mean speed on a peri-urban stretch regulated with an educational radar is $\mu = 80\text{ km/h}$, with a known population standard deviation of $\sigma = 10\text{ km/h}$. A neighborhood association claims that vehicles travel at a higher mean speed. To test this, they record the speed of a random sample of $n = 100$ vehicles and obtain a sample mean of $\bar{x} = 81.8\text{ km/h}$.

  1. a) Before carrying out any formal calculations, note that the observed difference is only $1.8\text{ km/h}$ over $80\text{ km/h}$. Estimate mentally or off the cuff the standard error of the mean ($\sigma/\sqrt{n}$) and reason whether a deviation of $1.8\text{ km/h}$ seems sufficient to be statistically significant or attributable to mere sampling chance.
  2. b) Formally set up the one-tailed test with $H_0: \mu = 80$ against $H_1: \mu > 80$. Calculate the test statistic $z_{\text{exp}}$ and its corresponding p-value.
  3. c) With a significance level of $\alpha = 5\,\%$ ($z_{0,05} = 1.645$), is the RSA's claim rejected? Compare the conclusion obtained with your initial estimate and reason what role the sample size ($n = 100$) played in the final verdict.
Solve
Practice★★★Not started
A study on youth mental health indicates that the daily mean time that Sixth Year students spend on TikTok is $120$ minutes, with a standard deviation of $30$ minutes. A…

A study on youth mental health indicates that the daily mean time that Sixth Year students spend on TikTok is $120$ minutes, with a standard deviation of $30$ minutes. A counsellor at a school believes that at their centre, due to the pressure of the Leaving Certificate exams, the mean time is significantly lower. They take a random sample of $50$ students and obtain a mean of $112$ minutes.

  1. a) Define the appropriate hypothesis test for the counsellor's belief.
  2. b) Calculate the p-value of the obtained sample.
  3. c) If a significance level of $1\%$ is used, what conclusion should the counsellor draw? What if the significance level were $5\%$?
Solve
Practice★★★Not started
An express courier company in Ireland guarantees a mean delivery time between counties of $\mu_0 = 24\text{ hours}$, with a known dispersion of…

An express courier company in Ireland guarantees a mean delivery time between counties of $\mu_0 = 24\text{ hours}$, with a known dispersion of $\sigma = 3\text{ hours}$. Management audits the service using the test $H_0: \mu = 24$ against $H_1: \mu > 24$ (suspicion of delays) at a significance level $\alpha = 0.05$ ($z_{0,05} = 1.645$).

  1. a) If the auditors examine a sample of $n = 36$ independent shipments, determine the threshold value of the sample mean, $\bar{x}_c$, above which $H_0$ would be rejected. That is, what is the minimum observed mean time that would raise management's alarms?
  2. b) Management considers it unacceptable that a sample mean of $\bar{x} = 24.6\text{ hours}$ is not sufficient to reject $H_0$ at the level $\alpha = 0.05$. Solve the inverse problem: what is the minimum sample size $n$ that the auditors should have collected so that a record of $\bar{x} = 24.6\text{ hours}$ would have been enough to reject $H_0$ at that same significance level?
  3. c) Analyze the theoretical expression of the critical value $\bar{x}_c = \mu_0 + z_\alpha \times \dfrac{\sigma}{\sqrt{n}}$. Justify what happens to the test's ability to detect minimal deviations of the true mean from the null hypothesis when $n$ approaches infinity, keeping $\alpha$ constant.
Solve

Test for a proportion

Standard normal distribution curve showing the rejection region in the right tail from the critical value z alpha and the experimental statistic z exp in the acceptance region. z_α rejection region zexp
Practice★☆☆Not started
Sara wants to check whether the proportion of users satisfied with her city's municipal bike-sharing service has decreased compared to the official historical figure,…

Sara wants to check whether the proportion of users satisfied with her city's municipal bike-sharing service has decreased compared to the official historical figure, which was $70\,\%$ ($p_0 = 0.70$). To do so, she surveys $n = 100$ randomly selected users and observes that $62$ of them report being satisfied (that is, $\hat{p} = 0.62$). In her notebook, Sara writes the following:

  1. Statement: $H_0: \hat{p} = 0.62$ versus $H_1: \hat{p} < 0.62$.

  2. Test statistic: $z = \dfrac{0.62 - 0.70}{\sqrt{\dfrac{0.62 \times 0.38}{100}}} = \dfrac{-0.08}{0.0485} \approx -1.65$.

  1. a) Sara has made two serious conceptual errors in her approach. Identify both errors and explain why they contradict the theoretical foundations of hypothesis testing.
  2. b) Correct Sara's procedure: formulate the null and alternative hypotheses accurately with the appropriate population parameters, and calculate the correct value of the experimental test statistic $z_{\text{exp}}$.
Solve
Practice★★☆Not started
In a sustainability study, it is known that two years ago $30\ \%$ of young people in a town used public transport to get to school. Following an environmental awareness…

In a sustainability study, it is known that two years ago $30\ \%$ of young people in a town used public transport to get to school. Following an environmental awareness campaign, we want to test whether this percentage has increased. A random sample of $150$ young people is taken, and it is observed that $54$ of them now use public transport.

From these data, and with a significance level of $5\ \%$, can it be concluded that the campaign was effective and the proportion of users has increased? Set up the corresponding hypothesis test.

p₀ = 0.30 z_α = ? α = 5% (Rejection) Sample Data n = 150 x = 54 p̂ = 54/150 = ? Hypotheses H₀: p ≤ 0.30 H₁: p > 0.30 Does p̂ fall in the rejection region? p̂ = ?
Solve
Practice★★☆Not started
A health centre claims that the proportion of smokers among young people aged between 16 and 18 is $15\ \%$. To verify this, a study is conducted on a sample of $400$…

A health centre claims that the proportion of smokers among young people aged between 16 and 18 is $15\ \%$. To verify this, a study is conducted on a sample of $400$ young people in that age range, revealing that $72$ of them smoke.

Calculate the p-value (the probability of obtaining a result as extreme as, or more extreme than, the observed result under the null hypothesis) for a two-tailed test. In light of the result, would you reject the health centre's claim at a standard significance level of $\alpha = 0.05$?

Solve

The relationship between confidence interval and hypothesis test

Graph illustrating the equivalence between a two-tailed confidence interval and the acceptance region of a test, showing whether the hypothesised parameter lies inside or outside the interval. CI 1−α μ₀ outside → H₀ is rejected

Margin of error method for a proportion

The $95\%$ confidence interval for a population proportion is $\hat{p} \pm 1.96\sqrt{\dfrac{\hat{p}(1-\hat{p})}{n}}$. Its largest possible radius is the margin of error, approximately $\dfrac{1}{\sqrt{n}}$. To test $H_0: p=p_0$ at $5\%$, reject $H_0$ if $p_0$ lies outside $\hat{p} \pm \dfrac{1}{\sqrt{n}}$.

Practice★★☆Not started
A study was conducted on the monthly leisure expenditure of university students in a city, assuming it follows a normal distribution with $\sigma = 20$ euros. A $95\ \%$…

A study was conducted on the monthly leisure expenditure of university students in a city, assuming it follows a normal distribution with $\sigma = 20$ euros. A $95\ \%$ confidence interval for the mean was obtained as $(75.1; 84.9)$.

Without carrying out new standardisation calculations, use the relationship between confidence intervals and hypothesis tests to answer: Would the null hypothesis $H_0: \mu = 70$ euros be rejected against $H_1: \mu \neq 70$ euros at a significance level of $\alpha = 0.05$? What if the null hypothesis were $H_0: \mu = 80$ euros? Justify your answer.

Solve
Practice★★☆Not started
In a canning plant in County Cork, the nominal net weight of beetroot jars must be $\mu = 250\text{ g}$. From historical controls, it is known that the population…

In a canning plant in County Cork, the nominal net weight of beetroot jars must be $\mu = 250\text{ g}$. From historical controls, it is known that the population standard deviation of the packaging process is $\sigma = 8\text{ g}$. To verify that the automatic filling machine has not become miscalibrated (neither above nor below), the quality team takes a random sample of $n = 64$ jars and obtains a mean weight of $\bar{x} = 252.2\text{ g}$. With a significance level $\alpha = 0.05$, three engineers propose three different ways to make the decision:

  • Aoife proposes constructing the $95\,\%$ confidence interval for the population mean and checking whether $\mu_0 = 250\text{ g}$ belongs to that interval.

  • Seán proposes calculating the standardized statistic $z_{\text{exp}}$ and comparing it with the two-tailed critical values $\pm 1.96$.

  • Niamh proposes directly calculating the exact p-value of the statistic and comparing it with $\alpha = 0.05$.

  1. a) Apply the procedures of Aoife and Seán. Show your calculations and explain why both necessarily lead to the same statistical decision in a two-tailed test.
  2. b) Suppose that the operations director needs an answer to the following question: “What was the exact probability of having obtained a deviation from the nominal weight as large as or larger than the observed one if the machine were perfectly calibrated?”. Justify which of the three methods directly answers that question, calculate it, and interpret the result in terms of evidence against the null hypothesis.
Solve
Practice★★★Not started
In a debate on sustainability, it is claimed that $75\%$ of young people in a city separate plastic packaging from the rest of the rubbish. To verify this, a sample of…

In a debate on sustainability, it is claimed that $75\%$ of young people in a city separate plastic packaging from the rest of the rubbish. To verify this, a sample of $150$ young people is selected, and it is observed that $105$ of them recycle correctly.

  1. a) Set up the hypothesis test to check whether the true proportion is lower than claimed.
  2. b) Is the initial claim acceptable for a significance level of $10\%$?
  3. c) Suppose that the true proportion were $65\%$. What decision would most likely be made with this test if the sample size were only $20$ people? Reason about the importance of sample size on the power of the test.
Solve
Practice★★☆Not started
According to the CSO's Census of Population, the percentage of Irish single-person households (where a single person lives) historically stood at $26\,\%$ (…

According to the CSO's Census of Population, the percentage of Irish single-person households (where a single person lives) historically stood at $26\,\%$ ($p_0 = 0.26$). A sociologist from Maynooth University claims that in major cities such as Dublin, Cork and Galway this percentage has increased significantly in recent years. To verify this, they select a simple random sample of $n = 400$ households from a large metropolitan area and find that $124$ of them are single-person.

  1. a) Mathematically justify whether the approximation of the sample proportion using a normal distribution is applicable, checking the theoretical conditions on the expected number of successes and failures under the assumption that the null hypothesis is true.
  2. b) Model the situation using a hypothesis test: state the null and alternative hypotheses corresponding to the sociologist's suspicion, and calculate the standardized test statistic $z_{\text{exp}}$.
  3. c) For a significance level of $1\,\%$ ($z_{0,01} = 2.33$), determine the rejection region and conclude with reasoning in the context of the problem whether there is sufficient evidence to support the sociologist's hypothesis.
Solve

Back to the start: If you analyse a sample of $36$ bags of crisps and obtain $\bar{x} = 148$ g with $\sigma = 6$ g, the statistic is $z_{exp} = \frac{148 - 150}{6 / \sqrt{36}} = -2$; since it falls in the rejection region for $\alpha = 0.05$ ($|-2| > 1.96$), you conclude that the manufacturer does not meet the promised $150$ g. For the counsellor, the answer depends on her sample and on the $\alpha$ she chose in advance.

Summary

See all the exercises in this section