Source: STAT 211 Engineering Statistics, Texas A&M University Difficulty: Intermediate | Prerequisites: Part 2 notes (sampling distributions, confidence intervals, Z and t distributions)
Tags: hypothesis testing, null hypothesis, alternative hypothesis, p-value, significance level, alpha, type I error, type II error, one-sample t-test, Z-test, matched pairs, paired t-test, STAT 211, Texas A&M, FE exam
Confidence intervals tell you a plausible range for a parameter. Hypothesis testing asks a sharper question: is there enough evidence in your sample to reject a specific claim about the population? This is the framework engineers use to decide whether a new material is stronger, whether a process change reduced defect rates, or whether two measurements are meaningfully different. Weeks 10 and 11 cover one-mean tests (both Z and t), tests for a proportion, and matched-pairs designs.
A hypothesis test sets up a "default" claim (null hypothesis) and checks whether the data are surprising enough to reject it. You compute a test statistic, find a p-value, and compare it to your chosen significance level. If p ≤ α, you reject the null. Matched-pairs tests handle the common situation where two measurements are taken on the same subjects.
Null hypothesis (H₀)
The default claim, typically a statement of "no effect" or "no difference." For example, H₀: μ = 100. Think of it as the assumption you keep unless the data give you strong enough reason to abandon it.
Alternative hypothesis (Hₐ or H₁)
The claim you are trying to find evidence for. It can be one-sided (Hₐ: μ > 100 or Hₐ: μ < 100) or two-sided (Hₐ: μ ≠ 100).
Significance level (α)
The threshold for "surprising enough." Common values are 0.01, 0.05, and 0.10. It is the maximum probability of rejecting H₀ when H₀ is actually true (i.e. the maximum Type I error rate you are willing to tolerate).
Test statistic
A standardised value that measures how far the sample result is from what H₀ predicts. For a one-mean test: Z = (x̄ , μ₀) / (σ / √n) or t = (x̄ , μ₀) / (s / √n).
p-value
The probability of observing a test statistic as extreme as (or more extreme than) the one you computed, assuming H₀ is true. A small p-value means the data are unlikely under H₀. In simple terms, it answers: "If there really were no effect, how weird would my data be?"
Type I error
Rejecting H₀ when it is actually true (a false alarm). The probability of a Type I error is α.
Type II error
Failing to reject H₀ when it is actually false (a missed detection). The probability of a Type II error is β.
Power
The probability of correctly rejecting a false H₀: Power = 1 , β. Higher power means a better chance of detecting a real effect.
One-tailed test (one-sided)
The alternative hypothesis specifies a direction: Hₐ: μ > μ₀ (right-tailed) or Hₐ: μ < μ₀ (left-tailed). The p-value is the area in one tail.
Two-tailed test (two-sided)
The alternative hypothesis is Hₐ: μ ≠ μ₀. The p-value is the area in both tails combined.
Matched pairs (paired data)
Two measurements taken on the same subject or on naturally paired units (e.g. before and after treatment on the same person, or two measurements on the same part). You analyse the differences d = x₁ , x₂, reducing the problem to a one-sample t-test on the differences.
Paired t-test
A one-sample t-test applied to the differences in matched-pair data. H₀: μ_d = 0 (no mean difference). The test statistic is t = (d̄ , 0) / (s_d / √n), with df = n , 1 where n is the number of pairs.
Every hypothesis test follows the same five steps:
State hypotheses: Write H₀ and Hₐ using the appropriate parameter (μ, p).
Choose α: Decide the significance level before looking at the data.
Compute the test statistic: Use the correct formula (Z or t, depending on whether σ is known).
Find the p-value: Use the standard normal table, t-table, or software.
Make a decision: If p ≤ α, reject H₀. If p > α, fail to reject H₀. State the conclusion in context.
Test statistic: Z = (x̄ , μ₀) / (σ / √n)
Use the standard normal table for p-values.
This appears in textbook problems and on the FE exam. In practice it is uncommon because σ is rarely known.
Test statistic: t = (x̄ , μ₀) / (s / √n), df = n , 1
Use the t-table for p-values.
Assumes the population is approximately normal, or that n is large enough for the CLT to apply.
Test statistic: Z = (p̂ , p₀) / √[p₀(1 , p₀) / n]
Note: the standard error uses the hypothesised value p₀ (not p̂), because under H₀ you assume p₀ is correct.
Normal approximation conditions: np₀ ≥ 5 and n(1 , p₀) ≥ 5.
Compute the difference for each pair: dᵢ = x₁ᵢ , x₂ᵢ.
Calculate d̄ and s_d from the differences.
Test statistic: t = (d̄ , 0) / (s_d / √n), df = n , 1 (where n = number of pairs).
This is simply a one-sample t-test on the d values.
The pairing removes variability between subjects, making the test more sensitive than treating the two groups as independent samples.
A two-sided hypothesis test at significance level α and a (1 , α) × 100% confidence interval give consistent results.
If the CI does not contain μ₀, you would reject H₀ at level α. If it does contain μ₀, you would fail to reject.
This duality is a useful check on your work.
P-value approach: Compute the p-value and compare to α. This is the more common method and the one software uses.
Critical value approach: Find the critical value(s) of Z or t for a given α, and check whether the test statistic falls in the rejection region. Both approaches always give the same decision.
One-mean Z-test statistic: Z = (x̄ , μ₀) / (σ / √n)
One-mean t-test statistic: t = (x̄ , μ₀) / (s / √n), df = n , 1
Proportion test statistic: Z = (p̂ , p₀) / √[p₀(1 , p₀) / n]
Paired t-test statistic: t = (d̄ , 0) / (s_d / √n), df = n , 1
Type I error probability: α Type II error probability: β Power: 1 , β
Hypothesis testing is how engineers validate that a process improvement actually works. If a factory tweaks a welding procedure, a paired t-test (before vs. after on the same joints) determines whether the strength difference is statistically meaningful or just noise. The FE exam tests this framework explicitly.
"Fail to reject H₀" does not mean H₀ is true. It means the data did not provide sufficient evidence against it. Absence of evidence is not evidence of absence.
Students often confuse the significance level (α) with the p-value. α is chosen before the test; the p-value is computed from the data.
Using p̂ instead of p₀ in the denominator of the proportion test statistic is a common error. Under H₀, you assume p₀ is the true proportion.
With matched-pairs data, students sometimes run a two-sample t-test instead of a paired t-test. If the data are paired, you must use the paired approach; ignoring the pairing throws away information and reduces power.
⚠️ The five-step hypothesis test procedure is the skeleton of every test question. Missing any step (especially stating hypotheses and writing a contextual conclusion) costs marks.
⚠️ One-sided vs. two-sided: read the problem carefully. Phrases like "is there evidence that the mean is greater than" signal one-sided. "Is there evidence that the mean differs from" signals two-sided.
⚠️ Matched-pairs problems are easily disguised. Look for "before/after," "same subject," "left hand vs. right hand," or any design where two measurements are linked.
⚠️ Know the duality between CIs and hypothesis tests. Exam problems sometimes ask you to use a CI to draw a hypothesis-test conclusion.
True or False: A p-value of 0.03 means there is a 3% chance that the null hypothesis is true.
Fill in the blank: In a matched-pairs test, you analyse the ___ of each pair.
True or False: If you increase α from 0.05 to 0.10, the probability of a Type II error increases.
Fill in the blank: In the test statistic for a proportion, the standard error uses ___ (p̂ or p₀) in the denominator.
True or False: A two-sided test at α = 0.05 and a 95% confidence interval always give the same conclusion about H₀.
Answers: 1. False (it is the probability of observing data this extreme if H₀ is true, not the probability that H₀ is true). 2. Differences (d values). 3. False (increasing α makes it easier to reject, so Type II error decreases). 4. p₀. 5. True.
Q: A manufacturer claims their bolts have a mean diameter of 10 mm. A sample of 25 bolts gives x̄ = 10.3 mm and s = 0.5 mm. At α = 0.05, is there evidence the mean diameter differs from 10 mm?
A: H₀: μ = 10, Hₐ: μ ≠ 10. t = (10.3 , 10) / (0.5 / √25) = 0.3 / 0.1 = 3.0 with df = 24. The two-tailed p-value for t = 3.0 with 24 df is approximately 0.006. Since 0.006 < 0.05, reject H₀. There is sufficient evidence that the mean diameter differs from 10 mm.
Q: In a paired study, 10 runners' times are measured before and after a training programme. The mean difference is d̄ = ,2.5 minutes with s_d = 3.0 minutes. Test whether the programme reduces times at α = 0.05.
A: H₀: μ_d = 0, Hₐ: μ_d < 0 (left-tailed, since a reduction means negative differences). t = (,2.5 , 0) / (3.0 / √10) = ,2.5 / 0.949 ≈ ,2.64 with df = 9. The one-tailed p-value is approximately 0.013. Since 0.013 < 0.05, reject H₀. There is evidence the programme reduces running times.
Q: What is the difference between a Type I and a Type II error in the context of quality control?
A: A Type I error means concluding a batch is defective when it is actually fine (false alarm, halting production unnecessarily). A Type II error means concluding a batch is fine when it is actually defective (missed detection, shipping bad product).
Q: A 95% CI for μ is (48, 55). Would you reject H₀: μ = 50 at α = 0.05?
A: No. 50 is inside the interval, so you would fail to reject H₀ at the 5% significance level.
The one-sample procedures here extend directly to two-sample tests (Week 13), where you compare two independent means or two proportions. The test statistic structure stays the same: (estimate , hypothesised value) / standard error. Power and Type II error connect to sample size planning and to the power analysis covered in the final weeks. The paired t-test reappears conceptually in regression (Weeks 15+), where you are testing whether a slope differs from zero.
hypothesis test, null hypothesis, alternative hypothesis, p-value, significance level, alpha, Type I error, Type II error, power, test statistic, one-sample Z-test, one-sample t-test, proportion test, one-tailed test, two-tailed test, rejection region, critical value, fail to reject, matched pairs, paired t-test, paired data, before and after, duality CI and hypothesis test, STAT 211, engineering statistics, FE exam, Texas A&M