πŸ§ͺ Hypothesis Testing Overview

A Level Maths Year 2 Β· Overview of the whole topic

Level 3 · Ages 17–18
1 The Big Idea

A hypothesis test asks one question: is this sample surprising enough to doubt a claim about the population? In Year 1 you tested a proportion $p$ using the binomial distribution. Year 2 (DfE content area O Β· Statistical hypothesis testing) applies exactly the same logic to two new situations.

The two new tests
Correlation:   $\mathrm{H}_0: \rho = 0$   β€” test statistic the sample correlation coefficient $r$
Normal mean:   $\mathrm{H}_0: \mu = \mu_0$   β€” test statistic the sample mean $\bar{x}$, with $\bar{X} \sim \mathrm{N}\!\left(\mu_0,\ \dfrac{\sigma^2}{n}\right)$
Nothing about the structure changes: hypotheses about a population parameter, a significance level, a critical region or $p$-value, and a conclusion in context. Only the distribution used to judge "surprising" is new.
Calculators allowed. Use your calculator for $r$ and for normal probabilities; critical values for $r$ come from a table supplied in the exam. Marks are for correct hypotheses, the correct distribution and a careful conclusion.
2 The Language You Need

This is a recap of the Year 1 vocabulary, which is examined again in Year 2. For the full treatment see The Language of Hypothesis Testing.

TermMeaning
Null hypothesis $\mathrm{H}_0$The default claim, assumed true for the test; always states a single value of the parameter.
Alternative hypothesis $\mathrm{H}_1$What we look for evidence of: $>$, $<$ (one-tailed) or $\neq$ (two-tailed).
Test statisticThe value calculated from the sample: $r$ or $\bar{x}$ in Year 2.
Significance levelThe probability threshold for rejecting $\mathrm{H}_0$, e.g. $5\%$.
Critical valueThe boundary of the critical region.
Critical regionThe set of values of the test statistic that lead to rejecting $\mathrm{H}_0$, written as inequalities, e.g. $r \geqslant 0.5494$ or $\bar{X} \leqslant 115.35$.
$p$-valueThe probability, assuming $\mathrm{H}_0$, of a result at least as extreme as the one observed.
Population parameter$\rho$ (population correlation) or $\mu$ (population mean). Hypotheses are about these, never about $r$ or $\bar{x}$.
Conclusions are never certain. Write "there is sufficient evidence at the $5\%$ level to suggest…" or "insufficient evidence to suggest…". Never "this proves" or "$\mathrm{H}_0$ is true".
3 The Core Techniques
Correlation testNormal mean test
Parameter$\rho$$\mu$
$\mathrm{H}_0$$\rho = 0$$\mu = \mu_0$
Test statistic$r$$\bar{x}$, or $z = \dfrac{\bar{x} - \mu_0}{\sigma/\sqrt{n}}$
Critical value fromTable of critical values of $r$ for sample size $n$Inverse normal
AssumptionRandom sample from a bivariate normal populationNormal population with known, unchanged $\sigma$; random sample
Worked Example 1 β€” A correlation test

For $14$ randomly chosen days, the correlation coefficient between daily rainfall and the number of umbrellas sold is $r = 0.58$. Test at the $2.5\%$ level whether there is positive correlation.

β‘ $\mathrm{H}_0: \rho = 0$, $\mathrm{H}_1: \rho > 0$, where $\rho$ is the population correlation coefficient between rainfall and umbrella sales.
β‘‘One-tailed $2.5\%$, $n = 14$: critical value $0.5324$.
β‘’$0.58 \geqslant 0.5324$: reject $\mathrm{H}_0$.
β‘£There is sufficient evidence at the $2.5\%$ level to suggest positive correlation between rainfall and umbrella sales.
Worked Example 2 β€” A normal mean test

$X \sim \mathrm{N}(\mu,\ 2^2)$. A sample of $16$ has mean $51.1$. Test $\mathrm{H}_0: \mu = 50$ against $\mathrm{H}_1: \mu > 50$ at the $1\%$ level.

β‘ Under $\mathrm{H}_0$: $\bar{X} \sim \mathrm{N}\!\left(50,\ \dfrac{4}{16}\right) = \mathrm{N}(50,\ 0.5^2)$.
β‘‘$p$-value: $\mathrm{P}(\bar{X} \geqslant 51.1) = 1 - \Phi(2.2) = 0.0139$.
β‘’$0.0139 > 0.01$: do not reject $\mathrm{H}_0$.
β‘£There is insufficient evidence at the $1\%$ level to suggest that $\mu > 50$. (At $5\%$ the result would be significant.)
4 The Hypothesis Testing Subtopics

The two Year 2 tests, and the page that covers each. Both belong to DfE content area O.

For the underlying distributions, see Regression and Exponential Models and The Normal Distribution. The Year 1 binomial test is in Binomial Hypothesis Tests.

5 Common Mistakes to Avoid
Hypotheses in terms of $r$ or $\bar{x}$. Write $\mathrm{H}_0: \rho = 0$ and $\mathrm{H}_0: \mu = 20$ β€” population parameters β€” and define them in context.
Forgetting to halve for a two-tailed test. A two-tailed test at $5\%$ uses $2.5\%$ in each tail, both for critical values and when comparing a one-tail probability.
Using $\sigma$ instead of $\sigma/\sqrt{n}$. The sample mean has standard deviation $\sigma/\sqrt{n}$.
Over-strong conclusions. Not rejecting $\mathrm{H}_0$ is not evidence that $\mathrm{H}_0$ is true; a significant correlation is not evidence of causation.
Choosing the tail after seeing the data. The direction of $\mathrm{H}_1$ comes from the claim in the question, not from the sign of $r$ or whether $\bar{x}$ is above or below $\mu_0$.
6 Quick Reference

Correlation $\mathrm{H}_0$

$\rho = 0$; $\mathrm{H}_1$: $\rho > 0$, $\rho < 0$ or $\rho \neq 0$.

Correlation decision

Reject if $|r| \geqslant$ critical value for $n$ (in the right direction).

Sample mean

$\bar{X} \sim \mathrm{N}(\mu,\ \sigma^2/n)$

Mean test statistic

$z = \dfrac{\bar{x} - \mu_0}{\sigma/\sqrt{n}}$

Critical $z$ (5%)

One tail $1.6449$; two tails $\pm 1.96$.

Critical $z$ (1%)

One tail $2.3263$; two tails $\pm 2.5758$.

$p$-value

Reject $\mathrm{H}_0$ if $p <$ significance level (per tail).

Critical region

Write as an inequality, e.g. $\bar{X} \geqslant 25.33$.

Conclusion

In context, with the level, non-assertive.

7 Practice Questions

Ten questions drawing on the whole Year 2 Hypothesis Testing section. Critical values of $r$ are on the Testing for Correlation page.

Question 1

Explain what is meant by (a) the significance level of a test, (b) the critical region.

β–Ά Show solution

(a) The probability threshold below which a result is considered too unlikely under $\mathrm{H}_0$ β€” so it is the probability of rejecting $\mathrm{H}_0$ when it is in fact true.

(b) The set of values of the test statistic for which $\mathrm{H}_0$ is rejected.

Question 2

Packets of rice should have mean mass $500$ g. A consumer group believes the mean has changed. Write suitable hypotheses.

β–Ά Show solution

$\mathrm{H}_0: \mu = 500$, $\mathrm{H}_1: \mu \neq 500$, where $\mu$ is the mean mass in grams of all packets. Two-tailed, since "changed" has no direction.

Question 3

For $12$ countries, $r = -0.52$ between average income and infant mortality. Test at the $5\%$ level for negative correlation.

β–Ά Show solution

$\mathrm{H}_0: \rho = 0$, $\mathrm{H}_1: \rho < 0$. Critical region ($n = 12$, $5\%$ one tail): $r \leqslant -0.4973$.

$-0.52 \leqslant -0.4973$: reject $\mathrm{H}_0$. Sufficient evidence of negative correlation between income and infant mortality.

Question 4

For $16$ pairs, $r = 0.43$. Test at the $5\%$ level whether there is any correlation.

β–Ά Show solution

$\mathrm{H}_0: \rho = 0$, $\mathrm{H}_1: \rho \neq 0$. Two tails at $5\%$, so use the $2.5\%$ column: $n = 16$ gives $0.4973$.

$0.43 < 0.4973$: do not reject $\mathrm{H}_0$. Insufficient evidence of correlation.

Question 5

$X \sim \mathrm{N}(\mu,\ 3^2)$. A sample of $25$ has mean $101.1$. Test $\mathrm{H}_0: \mu = 100$ against $\mathrm{H}_1: \mu > 100$ at the $5\%$ level.

β–Ά Show solution

$\bar{X} \sim \mathrm{N}(100,\ 0.6^2)$ under $\mathrm{H}_0$.

$\mathrm{P}(\bar{X} \geqslant 101.1) = 1 - \Phi(1.833) = 0.0334 < 0.05$

Reject $\mathrm{H}_0$: sufficient evidence at the $5\%$ level that $\mu > 100$.

Question 6

$X \sim \mathrm{N}(\mu,\ 4^2)$. Find the critical region for a test of $\mathrm{H}_0: \mu = 64$ against $\mathrm{H}_1: \mu \neq 64$ at the $1\%$ level using a sample of $16$.

β–Ά Show solution

$\sigma/\sqrt{n} = 1$; $0.5\%$ in each tail, $z = \pm 2.5758$.

Critical region: $\bar{X} \leqslant 61.42$ or $\bar{X} \geqslant 66.58$.

Question 7

A one-tailed test gives a $p$-value of $0.07$. State the conclusion at the $5\%$ and $10\%$ levels.

β–Ά Show solution

$5\%$: $0.07 > 0.05$, do not reject $\mathrm{H}_0$.

$10\%$: $0.07 < 0.10$, reject $\mathrm{H}_0$.

The evidence is moderate: convincing at a lenient level, not at a stricter one.

Question 8

A student writes "$\mathrm{H}_0: r = 0$". Explain the error.

β–Ά Show solution

$r$ is the sample correlation coefficient β€” it is known exactly once the data are collected, so there is nothing to test about it. Hypotheses are about the unknown population correlation coefficient: $\mathrm{H}_0: \rho = 0$.

Question 9

Which test (correlation, normal mean, or the Year 1 binomial test) suits each claim? (a) "More than $20\%$ of customers return their purchase." (b) "Taller people tend to have longer arm spans." (c) "The new fertiliser increases the mean yield per plant."

β–Ά Show solution

(a) Binomial test of a proportion: $\mathrm{H}_0: p = 0.2$, $\mathrm{H}_1: p > 0.2$.

(b) Correlation test: $\mathrm{H}_0: \rho = 0$, $\mathrm{H}_1: \rho > 0$.

(c) Normal mean test (yields continuous, assumed normal with known $\sigma$): $\mathrm{H}_1: \mu > \mu_0$.

Question 10

A farmer records the amount of fertiliser used and the yield for $10$ fields, obtaining $r = 0.68$.

(a) Test at the $1\%$ level whether there is positive correlation. (b) Would the conclusion change at the $5\%$ level? (c) Historically, yields per field are $\mathrm{N}(6.2,\ 0.9^2)$ tonnes. After a change of seed, $15$ fields have mean yield $6.65$ tonnes. Assuming the standard deviation is unchanged, test at the $5\%$ level whether the mean yield has increased. (d) Find the critical region for part (c).

β–Ά Show solution

(a) $\mathrm{H}_0: \rho = 0$, $\mathrm{H}_1: \rho > 0$. Critical value ($n = 10$, $1\%$): $0.7155$. $0.68 < 0.7155$: do not reject $\mathrm{H}_0$; insufficient evidence at $1\%$.

(b) At $5\%$ the critical value is $0.5494$; $0.68 \geqslant 0.5494$, so $\mathrm{H}_0$ would be rejected β€” yes, the conclusion changes.

(c) $\mathrm{H}_0: \mu = 6.2$, $\mathrm{H}_1: \mu > 6.2$. $\sigma/\sqrt{n} = 0.9/\sqrt{15} = 0.2324$.

$z = \dfrac{0.45}{0.2324} = 1.936$; $p = 1 - \Phi(1.936) = 0.0264 < 0.05$. Reject $\mathrm{H}_0$: sufficient evidence at the $5\%$ level that the mean yield has increased.

(d) $6.2 + 1.6449 \times 0.2324 = 6.58$, so the critical region is $\bar{X} \geqslant 6.58$ (2 d.p.). Indeed $6.65 \geqslant 6.58$ βœ“

Hypothesis Testing Overview · A Level Maths Year 2 · Created with MathJax