
Why Hypothesis Testing Deserves a Method, Not a Template
In H2 Mathematics (9758), hypothesis testing appears regularly in the statistics section of Paper 2. On paper it looks like the most routine topic in the syllabus. You write two hypotheses, press a few buttons on the graphing calculator, and say ‘reject’ or ‘do not reject’. It is also where strong students quietly lose marks. Common causes are a hypothesis written in terms of x̄ instead of μ, a variance divided by n instead of n − 1, a missing line about the Central Limit Theorem, or a conclusion that claims to ‘prove’ something no test can prove.
The root cause is almost always the same. The student has memorised what a hypothesis test looks like without understanding what it argues. Once you see the argument, every question becomes a variation of the same five lines. That covers z-tests and t-tests, one-tailed and two-tailed tests, and the ‘find the critical region’ and ‘find the least sample size’ parts. This guide builds that framework and then applies it to three exam-style questions.
The Big Idea: A Test Is an Argument From Surprise
Every hypothesis test asks one question: if the claim were true, how surprising is the sample we actually got?
- The null hypothesis H0 is the claim we provisionally assume. It usually says ‘nothing has changed’ (μ = μ0).
- The alternative hypothesis H1 is what we are looking for evidence of (μ < μ0, μ > μ0 or μ ≠ μ0).
- The p-value is the probability, assuming H0 is true, of obtaining a sample result at least as extreme as the one observed. It measures surprise. The smaller the p-value, the harder the data is to explain under H0.
- The level of significance α is the surprise threshold, fixed before looking at the data. If p-value ≤ α, the sample is too surprising to put down to chance, so we reject H0.
Think of a courtroom. The defendant (H0) is presumed innocent, and the prosecution needs enough evidence to pass a set threshold before a conviction. If the evidence falls short, the verdict is ‘not guilty’, which is not the same as ‘proven innocent’. This analogy explains why you must never write ‘accept H0’, and why ‘do not reject H0’ is the correct phrase. Once students see it, the conclusion wording no longer feels arbitrary.
The Five-Line Framework
Every hypothesis test answer at H2 level can be written in five lines. If you know what each line is for, you will always know what to write next.
- Hypotheses. State H0 and H1 in terms of the population mean μ, and define μ in context (for example, ‘where μ is the population mean volume, in ml, of drink in a bottle’). The direction of H1 comes from the wording of the question, never from the sample.
- Distribution under H0, with justification. State the distribution of the test statistic assuming H0 is true. Then say why that distribution is valid: the population is given as normal, the Central Limit Theorem applies, or normality is assumed for a t-test.
- Test statistic and p-value. Compute the observed value of z or t and the corresponding p-value, or compare it with the critical value.
- Decision. If p-value ≤ α, reject H0. If p-value > α, do not reject H0.
- Conclusion in context. Write ‘There is sufficient (or insufficient) evidence at the α% level of significance to conclude that …’, followed by H1 in words.
Lines 1 and 2 are where the thinking happens. Lines 3 to 5 are almost mechanical once those are right.
Choosing the Right Test: Three Questions
Line 2 depends on three facts about the situation. Ask them in order:
- Is the population variance σ2 known?
- Is the population normally distributed, either as given or as something you may assume?
- Is the sample large? In JC, this is commonly taken as n ≥ 30, and questions usually make it clear.
The answers sort every syllabus question into one of three cases:
- Case A: normal population, σ2 known, any n. Z = (X̄ − μ0) / (σ/√n) ~ N(0, 1) exactly. If the population is not normal but n is large, the same statistic is approximately N(0, 1) by the Central Limit Theorem.
- Case B: any population, σ2 unknown, n large. Z = (X̄ − μ0) / (s/√n) is approximately N(0, 1). Here the unbiased estimate s2 replaces σ2, and the Central Limit Theorem makes X̄ approximately normal.
- Case C: normal population, σ2 unknown, n small. T = (X̄ − μ0) / (S/√n) follows a t-distribution with n − 1 degrees of freedom.
One situation is missing: a small sample from a population that is not normal, with unknown variance. None of the syllabus tests is valid there. That is why examiners ask you to state an assumption in Case C. Without normality, the t-test has no foundation.
The Unbiased Estimate of Population Variance
Whenever σ2 is unknown, you replace it with
s2 = (1/(n − 1)) Σ(x − x̄)2 = (1/(n − 1)) [ Σx2 − (Σx)2/n ]
For coded data given as Σ(x − a) and Σ(x − a)2, replace x with (x − a) throughout. Then x̄ = a + Σ(x − a)/n, and s2 = (1/(n − 1)) [ Σ(x − a)2 − (Σ(x − a))2/n ]. Shifting every value by the same constant moves the mean but leaves the spread unchanged, which is why the coding works.
Why divide by n − 1 and not n? The deviations are measured from x̄, which is calculated from the same data, so they are systematically a little smaller than deviations from the true μ. Dividing by n − 1 corrects that underestimate. On the TI-84, this is the value labelled Sx, not σx. Reading the wrong one is a single keystroke, but it changes the answer.
Worked Examples
Example 1: Known Variance, One-Tailed z-Test (Case A)
The volume of drink in bottles filled by a machine is normally distributed with standard deviation 4 ml. The manufacturer claims that the mean volume is 500 ml. A consumer group suspects that the bottles are under-filled. A random sample of 25 bottles has mean volume 498.3 ml. Test, at the 5% level of significance, whether the consumer group’s suspicion is justified.
Line 1. Let μ be the population mean volume, in ml, of drink in a bottle. H0: μ = 500 against H1: μ < 500. The word ‘under-filled’ tells you the test is left-tailed.
Line 2. The population is normal with known σ = 4. Under H0, X̄ ~ N(500, 42/25), i.e. N(500, 0.64), exactly.
Line 3. z = (498.3 − 500) / (4/√25) = −1.7 / 0.8 = −2.125, so the p-value = P(Z ≤ −2.125) ≈ 0.0168.
Line 4. Since 0.0168 ≤ 0.05, reject H0.
Line 5. There is sufficient evidence at the 5% level of significance to conclude that the mean volume of drink in a bottle is less than 500 ml.
Follow-up (a): The Meaning of ‘5% Level of Significance’
A typical 1-mark part asks: ‘State, in context, the meaning of the 5% level of significance.’ The answer: there is a probability of 0.05 of concluding that the mean volume is less than 500 ml when in fact it is 500 ml. In other words, α is the probability of wrongly rejecting a true H0. The answer is written in context, about the bottles. A generic textbook definition usually earns nothing.
Follow-up (b): The Critical Region for x̄
For a left-tailed test at 5%, reject H0 when z ≤ −1.6449. Converting back to the sample mean gives x̄ ≤ 500 − 1.6449 × 0.8 ≈ 498.684. State the critical region as x̄ ≤ 498.68. Quote enough decimal places, and round so that the region you state stays inside the true one.
The trap here is that 498.684 rounded to 3 significant figures is 499. A critical region of x̄ ≤ 499 would wrongly include a sample mean of 498.9. When a critical value sits close to the hypothesised mean, give enough figures to keep the answer meaningful.
Follow-up (c): The Least Sample Size
If the sample mean had instead been 498.8 ml, find the least sample size n for which the consumer group’s suspicion would be justified at the 5% level.
We need (498.8 − 500) / (4/√n) ≤ −1.6449, i.e. 0.3√n ≥ 1.6449. So √n ≥ 5.483 and n ≥ 30.06. The least sample size is n = 31.
Always round n up, then check the boundary. With n = 30, z = −0.3√30 ≈ −1.643, which does not reach −1.6449, so H0 is not rejected. That two-line check confirms the answer.
Example 2: Large Sample, Unknown Variance, Two-Tailed (Case B)
A school claims that students spend an average of 30 minutes on a daily online quiz. A teacher records the time, x minutes, taken by a random sample of 50 students, with the results Σ(x − 30) = 45 and Σ(x − 30)2 = 1080. Test, at the 5% level of significance, whether the mean time differs from 30 minutes.
Unbiased estimates first. x̄ = 30 + 45/50 = 30.9, and s2 = (1/49)(1080 − 452/50) = 1039.5/49 ≈ 21.214.
Line 1. Let μ be the population mean time, in minutes, that a student spends on the quiz. H0: μ = 30 against H1: μ ≠ 30. The word ‘differs’ makes this a two-tailed test.
Line 2. The distribution of quiz times is unknown. Since n = 50 is large, by the Central Limit Theorem, X̄ ~ N(30, 21.214/50) approximately under H0.
Line 3. z = (30.9 − 30) / √(21.214/50) ≈ 1.382. For a two-tailed test, the p-value = 2 × P(Z ≥ 1.382) ≈ 0.167.
Line 4. Since 0.167 > 0.05, do not reject H0.
Line 5. There is insufficient evidence at the 5% level of significance to conclude that the mean time students spend on the quiz differs from 30 minutes.
The insight. We never assumed quiz times were normal, and we did not need to. The Central Limit Theorem makes the sample mean approximately normal, whatever the shape of the population. Students who write ‘X ~ N(30, …) by CLT’ have applied the right theorem to the wrong variable, and they lose the mark. Note also that we have not shown the mean is 30 minutes. We have only shown that this sample gives no strong reason to doubt it.
Example 3: Small Sample, t-Test, and Why α Comes First (Case C)
A manufacturer claims that its batteries have a mean lifetime of 20 hours. The lifetimes, in hours, of a random sample of 8 batteries are:
19.2, 20.1, 18.7, 19.5, 20.4, 18.9, 19.8, 19.0
Test, at the 5% level of significance, whether the mean lifetime is less than claimed, stating any assumption you make.
Assumption. The lifetimes of the batteries are normally distributed. This is required because the sample is small and σ2 is unknown. With only 8 observations, the Central Limit Theorem cannot be relied on.
Unbiased estimates. x̄ = 155.6/8 = 19.45. Σ(x − x̄)2 = 2.58, so s2 = 2.58/7 ≈ 0.36857 and s ≈ 0.60710.
Line 1. Let μ be the population mean lifetime, in hours, of a battery. H0: μ = 20 against H1: μ < 20.
Line 2. Under H0, T = (X̄ − 20) / (S/√8) ~ t(7).
Line 3. t = (19.45 − 20) / (0.60710/√8) ≈ −2.562, so the p-value = P(T ≤ −2.562) ≈ 0.0187.
Line 4. Since 0.0187 ≤ 0.05, reject H0.
Line 5. There is sufficient evidence at the 5% level of significance to conclude that the mean lifetime of the batteries is less than 20 hours.
The Twist: Same Data, Different Verdict
Now repeat the test at the 1% level. The p-value is still 0.0187, but 0.0187 > 0.01, so we do not reject H0. The data is identical and the conclusion is the opposite. This is why α must be fixed before the data is examined, and why every conclusion must quote the level it was made at.
It also answers a common reverse question: ‘find the set of values of α for which H0 is rejected’. We reject exactly when p-value ≤ α, so the answer is α ≥ 1.87, with α expressed as a percentage.
Why Not Just Use z?
Suppose you had wrongly used the normal distribution. You would get P(Z ≤ −2.562) ≈ 0.0052, a p-value more than three times smaller, which overstates the evidence. The t-distribution has heavier tails because s is itself an estimate from only 8 values and could be some way off. The wider spread accounts for that extra uncertainty. That is the reason the t-test exists, and once you understand it you will not confuse the two tests.
Exam Traps That Cost Marks
- Hypotheses about the sample, not the population. H0: x̄ = 500 is wrong. Hypotheses are always about μ, and μ must be defined in context.
- Letting the data choose the tail. If the question says ‘has changed’, the test is two-tailed even if the sample mean happens to be below μ0. Take the direction from the question, and leave the data until Line 3.
- Dividing by n, or reading σx off the calculator. The unbiased estimate divides by n − 1. On the GC, use Sx.
- Applying the CLT to the wrong variable. The CLT says X̄ is approximately normal for large n. It says nothing about X itself.
- Forgetting the assumption in a t-test. State that the population is normally distributed. If an ‘explain’ part follows, say why the assumption is needed.
- Writing ‘accept H0’ or ‘H1 is proven’. A test only measures evidence. Use ‘reject’ or ‘do not reject’, and ‘sufficient’ or ‘insufficient evidence’.
- Conclusions without context or level. ‘Reject H0’ on its own is a decision, not a conclusion. Line 5 must mention the significance level and the real-world quantity.
- Misreading the p-value. The p-value is not the probability that H0 is true. It is the probability of getting data at least this extreme, calculated on the assumption that H0 is true.
- Two-tailed p-values. Either double the one-tail probability and compare it with α, or keep the one-tail probability and compare it with α/2. Comparing a single tail with the full α is an error that is easy to miss, and it makes the test twice as lenient as stated.
- Rounding in reverse questions. Round least sample sizes up. Give critical regions to enough figures and round them inwards. Always check the boundary value.
- Forgetting why the sample must be random. A random sample makes the observations independent and representative of the population. The distribution in Line 2 depends on this.
How to Practise Hypothesis Testing Effectively
Hypothesis testing rewards careful practice more than volume. Eight questions done with attention to each line are worth more than twenty done on autopilot.
- Sort before you solve. Take ten past-year or school prelim questions. Without calculating anything, classify each one as Case A, B or C, and write only Lines 1 and 2. This trains the decision where most errors begin.
- Write all five lines every time. The GC’s Z-Test or T-Test function can do Line 3 in seconds. Still write the hypotheses, the distribution with its justification, and the full conclusion in context. Examiners mark the argument, not the button presses.
- Build a bank of ‘explain’ sentences in context. Cover the meaning of the significance level, the meaning of the p-value, why the CLT applies, why normality must be assumed and why the sample must be random. Practise each one until you can adapt it to any context in a single sentence.
- Do the reverse questions on purpose. These include finding the critical region, the least n, the range of μ0 or x̄, and the set of α. Each is just Line 3 worked backwards, and they are where the framework is most useful.
- Mark against the wording, not just the answer. A correct p-value followed by ‘accept H0’ still loses a mark. Check your phrasing as strictly as you check your numbers.
At Intuitional, our small-group H2 Mathematics classes in Teck Whye teach statistics as a chain of reasoning rather than a set of templates, as we do with every topic. Students practise saying the argument aloud: assume H0, measure the surprise, compare it with the threshold, and conclude in context. With enough practice, the five lines become automatic. Hypothesis testing then becomes one of the most reliable sources of marks on the paper.