PRESTIGE ED
N8: Confidence Intervals: One-Sample
Node N8 — Section 1

Why This Concept Exists

A point estimate (like \(\bar{X}\)) tells you the best single guess for a parameter, but it tells you nothing about the uncertainty in that guess. Confidence intervals (CIs) quantify this uncertainty by providing a range of plausible values for the unknown parameter, together with a guaranteed long-run coverage probability.

The confidence interval framework is the single most practically important result in PTS2. It directly answers the question: "What can I reliably say about the population parameter, given my sample data?" The construction method used here — the pivotal quantity approach — is the template for every CI you will encounter in the remainder of the course.

Leverage: Confidence intervals appear in every PTS2 exam, typically worth 12-16 marks across the paper. The z-interval, t-interval, proportion CI, and variance interval are all independently testable. The inversion principle (deriving a CI from a hypothesis test) is an examinable technique worth 4-6 marks.

This node covers four types of one-sample CIs, each arising from a different pivotal quantity: \(\bar{X} \pm z_{\alpha/2}\,\dfrac{\sigma}{\sqrt{n}}\)
\(\bar{X} \pm t_{n-1,\alpha/2}\,\dfrac{S}{\sqrt{n}}\)
\(\hat{p} \pm z_{\alpha/2}\,\sqrt{\dfrac{\hat{p}(1-\hat{p})}{n}}\)
\(\left[\dfrac{(n-1)S^2}{\chi^2_{1-\alpha/2, n-1}},\;\dfrac{(n-1)S^2}{\chi^2_{\alpha/2, n-1}}\right]\)

The inversion principle is also covered: any hypothesis test can be inverted to produce a confidence interval, and vice versa. This is a deep conceptual result that connects two seemingly different forms of inference.


Node N8 — Section 2

Prerequisites

Before engaging with this node, you must be comfortable with:

  • Sampling distributions (N6): \(\bar{X} \sim N(\mu,\sigma^2/n)\), \(t\)-distribution, \(\chi^2\)-distribution. You must know which distribution to use in which scenario.
  • Standard normal critical values: \(z_{\alpha/2}\) such that \(P(Z > z_{\alpha/2}) = \alpha/2\). Common values: \(z_{0.025} = 1.96\), \(z_{0.05} = 1.645\), \(z_{0.005} = 2.576\).
  • Chi-squared critical values: \(\chi^2_{\alpha, \nu}\) such that \(P(\chi^2(\nu) > \chi^2_{\alpha, \nu}) = \alpha\).
  • Central Limit Theorem: For large \(n\), \(\bar{X}\) is approximately normal even if the parent distribution is not normal.
  • Binomial distribution: \(X \sim \text{Bin}(n, p)\), with \(E[X] = np\) and \(\text{Var}(X) = np(1-p)\).
  • Algebraic manipulation: Rearranging inequalities to isolate the parameter on one side.
Key concept: Pivotal Quantity A pivotal quantity is a function of the data and the parameter whose distribution does not depend on the unknown parameter. This is the core idea behind every CI in this node.

Node N8 — Section 3

Core Exposition

3.1 The Pivotal Quantity Approach

The pivotal quantity method is a four-step algorithm that works for every type of CI:

Algorithm:
1. Identify a pivotal quantity \(Q(X_1, \ldots, X_n; \theta)\) whose distribution is known and does not depend on \(\theta\).
2. Choose critical values \(c_1, c_2\) such that \(P(c_1 \leq Q \leq c_2) = 1 - \alpha\).
3. Rearrange the inequality to isolate \(\theta\).
4. State the confidence interval: \([\text{lower}(\text{data}),\ \text{upper}(\text{data})]\).
What "95% confidence" means: If we repeated the sampling process infinitely many times, 95% of the constructed intervals would contain the true parameter value. It does not mean "there is a 95% probability that \(\mu\) lies in this interval" — \(\mu\) is fixed, not random! The randomness is in the endpoints.

3.2 Z-Interval (Known Variance)

When the data are normal with known variance \(\sigma^2\), the pivotal quantity is:

\(Z = \dfrac{\bar{X} - \mu}{\sigma/\sqrt{n}} \sim N(0, 1)\)
Derivation \(P\!\left(-z_{\alpha/2} \leq \dfrac{\bar{X} - \mu}{\sigma/\sqrt{n}} \leq z_{\alpha/2}\right) = 1 - \alpha\)
\(P\!\left(\bar{X} - z_{\alpha/2}\dfrac{\sigma}{\sqrt{n}} \leq \mu \leq \bar{X} + z_{\alpha/2}\dfrac{\sigma}{\sqrt{n}}\right) = 1 - \alpha\)

The \((1-\alpha) \times 100\%\) CI for \(\mu\) is:

\([\bar{X} - z_{\alpha/2}\sigma/\sqrt{n},\; \bar{X} + z_{\alpha/2}\sigma/\sqrt{n}]\)

3.3 T-Interval (Unknown Variance)

When \(\sigma^2\) is unknown, we replace it with the sample variance \(S^2\) and use the t-distribution:

\(T = \dfrac{\bar{X} - \mu}{S/\sqrt{n}} \sim t(n-1)\)

The \((1-\alpha) \times 100\%\) CI for \(\mu\) is:

\([\bar{X} - t_{n-1, \alpha/2}\, S/\sqrt{n},\; \bar{X} + t_{n-1, \alpha/2}\, S/\sqrt{n}]\)

3.4 CI for a Population Proportion

For a binomial setting where \(X \sim \text{Bin}(n, p)\) and \(\hat{p} = X/n\), the pivotal quantity (for large \(n\)) is:

\(Z = \dfrac{\hat{p} - p}{\sqrt{p(1-p)/n}} \approx N(0, 1)\)

The approximate \((1-\alpha) \times 100\%\) Wald CI for \(p\) is:

\([\hat{p} - z_{\alpha/2}\sqrt{\hat{p}(1-\hat{p})/n},\; \hat{p} + z_{\alpha/2}\sqrt{\hat{p}(1-\hat{p})/n}]\)

3.5 CI for a Population Variance

For normal data with unknown \(\sigma^2\), the pivotal quantity is:

\(\dfrac{(n-1)S^2}{\sigma^2} \sim \chi^2(n-1)\)
Derivation \(P\!\left(\chi^2_{1-\alpha/2, n-1} \leq \dfrac{(n-1)S^2}{\sigma^2} \leq \chi^2_{\alpha/2, n-1}\right) = 1 - \alpha\)
Take reciprocals (which reverses the inequalities):
\(P\!\left(\dfrac{1}{\chi^2_{\alpha/2, n-1}} \leq \dfrac{\sigma^2}{(n-1)S^2} \leq \dfrac{1}{\chi^2_{1-\alpha/2, n-1}}\right) = 1 - \alpha\)
Multiply by \((n-1)S^2\):
\(P\!\left(\dfrac{(n-1)S^2}{\chi^2_{\alpha/2, n-1}} \leq \sigma^2 \leq \dfrac{(n-1)S^2}{\chi^2_{1-\alpha/2, n-1}}\right) = 1 - \alpha\)

The \((1-\alpha) \times 100\%\) CI for \(\sigma^2\) is:

\(\left[\dfrac{(n-1)S^2}{\chi^2_{\alpha/2, n-1}},\;\dfrac{(n-1)S^2}{\chi^2_{1-\alpha/2, n-1}}\right]\)

3.6 The Inversion Principle

Every confidence interval can be derived by inverting a hypothesis test. Specifically, a \(100(1-\alpha)\%\) CI for \(\theta\) is the set of all values \(\theta_0\) for which the test of \(H_0: \theta = \theta_0\) versus \(H_1: \theta \neq \theta_0\) would not be rejected at level \(\alpha\).

CI by inversion: Find all \(\theta_0\) such that \(\left|\dfrac{\bar{X} - \theta_0}{\text{SE}}\right| \leq z_{\alpha/2}\).
This gives: \(\bar{X} - z_{\alpha/2} \cdot \text{SE} \leq \theta_0 \leq \bar{X} + z_{\alpha/2} \cdot \text{SE}\).

Node N8 — Section 4

Worked Examples

Example 1: Z-Interval for Mean (Known Variance)

A machine fills bottles with a mean volume \(\mu\) and known standard deviation \(\sigma = 1.5\) ml. A random sample of 25 bottles has mean \(\bar{x} = 497.2\) ml.

(a) Construct a 95% CI for \(\mu\).

(b) Construct a 99% CI for \(\mu\).

(c) What is the minimum sample size needed to achieve a margin of error of at most 0.5 ml at 95% confidence?

Part (a): 95% CI \(\sigma = 1.5\), \(n = 25\), \(\bar{x} = 497.2\), \(z_{0.025} = 1.96\).
Margin of error: \(1.96 \times \dfrac{1.5}{\sqrt{25}} = 1.96 \times 0.3 = 0.588\).
95% CI: \(497.2 \pm 0.588 = [496.612,\; 497.788]\).
Part (b): 99% CI \(z_{0.005} = 2.576\).
Margin of error: \(2.576 \times 0.3 = 0.773\).
99% CI: \(497.2 \pm 0.773 = [496.427,\; 497.973]\).

Notice: the 99% CI is wider than the 95% CI. Higher confidence requires a wider interval.
Part (c): Required Sample Size We need: \(z_{0.025} \times \dfrac{\sigma}{\sqrt{n}} \leq 0.5\).
\(1.96 \times \dfrac{1.5}{\sqrt{n}} \leq 0.5\)
\(\sqrt{n} \geq \dfrac{1.96 \times 1.5}{0.5} = 5.88\)\ \(n \geq 34.57\)
So we need \(n \geq 35\) bottles.

Example 2: T-Interval for Mean (Unknown Variance)

A sample of 9 observations from a normal population has \(\bar{x} = 42.3\) and \(s = 3.8\). Construct a 90% CI for \(\mu\).

Solution \(n = 9\), \(\bar{x} = 42.3\), \(s = 3.8\), \(\text{d.f.} = 8\).
\(t_{8, 0.05}\) from tables: \(t_{8, 0.05} = 1.860\).
Standard error: \(\dfrac{s}{\sqrt{n}} = \dfrac{3.8}{3} = 1.267\).
Margin of error: \(1.860 \times 1.267 = 2.356\).
90% CI: \(42.3 \pm 2.356 = [39.944,\; 44.656]\).

Example 3: CI for a Proportion

In a survey of 200 people, 73 said they support a policy. Construct a 95% CI for the true proportion \(p\).

Solution \(\hat{p} = 73/200 = 0.365\), \(n = 200\), \(z_{0.025} = 1.96\).
Standard error: \(\sqrt{\dfrac{0.365 \times 0.635}{200}} = \sqrt{0.001159} = 0.0340\).
Margin of error: \(1.96 \times 0.0340 = 0.0667\).
95% CI: \(0.365 \pm 0.0667 = [0.2983,\; 0.4317]\).

Check conditions: \(n\hat{p} = 73 > 5\) and \(n(1-\hat{p}) = 127 > 5\). \(\checkmark\) Normal approximation is valid.

Example 4: CI for Variance

A sample of 15 batteries has a sample standard deviation of \(s = 1.2\) hours. Construct a 95% CI for the population variance \(\sigma^2\).

Solution \(n = 15\), \(\text{d.f.} = 14\), \(s^2 = 1.44\).
Critical values from chi-squared tables:\
\(\chi^2_{0.025, 14} = 26.119\) (upper 2.5% point)\ \(\chi^2_{0.975, 14} = 5.629\) (upper 97.5% point = lower 2.5% point).

\((n-1)S^2 = 14 \times 1.44 = 20.16\).

CI for \(\sigma^2\): \(\left[\dfrac{20.16}{26.119},\;\dfrac{20.16}{5.629}\right] = [0.772,\; 3.581]\).
CI for \(\sigma\): \([\sqrt{0.772},\;\sqrt{3.581}] = [0.879,\; 1.892]\).

Node N8 — Section 5

Pattern Recognition & Examiner Traps

Trap 1: Using z-scores when σ is unknown The z-interval is only valid when σ is known. In practice, σ is almost never known, so the t-interval is the correct choice. The most common mistake is using the z-critical value when the problem gives the sample standard deviation.
WRONG Using \(z_{0.025} = 1.96\) for a CI when only the sample standard deviation is available.
RIGHT Use \(t_{n-1, 0.025}\) when \(\sigma\) is unknown and estimated by \(S\). The t-critical value is always larger than the z-critical value, giving a wider (more honest) interval.
Trap 2: Confusing chi-squared critical values The chi-squared distribution is not symmetric, so the lower and upper critical values are not simple negatives of each other. You must look up both \(\chi^2_{\alpha/2}\) and \(\chi^2_{1-\alpha/2}\) separately.
WRONG Using \(\pm 1.96\)-style symmetry for chi-squared critical values. The lower 2.5% point is NOT the negative of the upper 2.5% point.
RIGHT \(\chi^2_{1-\alpha/2, n-1}\) is the smaller value (closer to zero), \(\chi^2_{\alpha/2, n-1}\) is the larger value. The CI for \(\sigma^2\) has the larger chi-squared in the denominator of the lower bound.
Trap 3: Misinterpreting "95% confidence" Saying "there is a 95% probability that \(\mu\) lies in the interval" is technically incorrect. \(\mu\) is a fixed, unknown constant. The correct interpretation is: "If we constructed many such intervals from repeated samples, 95% of them would contain \(\mu\)." The randomness is in the interval endpoints, not in \(\mu\).
Trap 4: Using the Wald CI for small samples with extreme proportions When \(p\) is near 0 or 1, or when \(n\) is small, the Wald CI \(\hat{p} \pm z\sqrt{\hat{p}(1-\hat{p})/n}\) can perform poorly (actual coverage far from nominal). For PTS2 exams, the Wald CI is expected unless an alternative is explicitly requested. Always verify \(n\hat{p} \geq 5\) and \(n(1-\hat{p}) \geq 5\).
Examiner patterns:
  • "Find a 95% CI for μ" — identify whether σ is known (z-interval) or unknown (t-interval). The critical clue is whether the problem gives σ or \(S\).
  • "Find the minimum sample size" — use the margin of error formula and solve for \(n\). Round up to the nearest integer.
  • "Find a CI for the variance" — use the chi-squared pivotal quantity. Remember the asymmetry.
  • "Construct a CI by inverting a test" — write the acceptance region of the test and solve for \(\theta_0\).

Node N8 — Section 6

Connections

N8 connects to everything that follows:
  • ← N6 (Sampling Distributions): Every CI formula is derived directly from a sampling distribution result. The t-interval exists because \(\bar{X} - \mu)/(S/\sqrt{n}) \sim t(n-1)\). The variance CI exists because \((n-1)S^2/\sigma^2 \sim \chi^2(n-1)\). The z-interval exists because \((\bar{X}-\mu)/(\sigma/\sqrt{n}) \sim N(0,1)\). Without N6, N8 is impossible.
  • → N9 (Two-Sample CIs): N9 extends N8's approach to differences of means \(\mu_1 - \mu_2\) and ratios of variances \(\sigma_1^2/\sigma_2^2\).
  • → N10-N12 (Hypothesis Tests): The duality between CIs and hypothesis tests (inversion principle) means that every CI formula immediately produces a corresponding test. If 0 is in a \(95\%\) CI for \(\mu_1 - \mu_2\), we cannot reject \(H_0: \mu_1 = \mu_2\) at the 5% level.

Node N8 — Section 7

Summary Table

ParameterConditionsPivotal QuantityCI Formula
\(\mu\) (mean)Normal, \(\sigma\) known\(Z = \dfrac{\bar{X}-\mu}{\sigma/\sqrt{n}} \sim N(0,1)\)\(\bar{X} \pm z_{\alpha/2}\sigma/\sqrt{n}\)
\(\mu\) (mean)Normal, \(\sigma\) unknown\(T = \dfrac{\bar{X}-\mu}{S/\sqrt{n}} \sim t(n-1)\)\(\bar{X} \pm t_{n-1, \alpha/2} S/\sqrt{n}\)
\(p\) (proportion)Large \(n\)\(Z = \dfrac{\hat{p}-p}{\sqrt{p(1-p)/n}} \approx N(0,1)\)\(\hat{p} \pm z_{\alpha/2}\sqrt{\hat{p}(1-\hat{p})/n}\)
\(\sigma^2\) (variance)Normal\(\dfrac{(n-1)S^2}{\sigma^2} \sim \chi^2(n-1)\)\(\left[\frac{(n-1)S^2}{\chi^2_{\alpha/2}},\;\frac{(n-1)S^2}{\chi^2_{1-\alpha/2}}\right]\)
Known vs Unknown σ If σ is given in the problem, use z. If only the sample standard deviation S is available, use t. This is the single most important decision in CI construction.
Chi-Squared Asymmetry The chi-squared CI for variance is NOT symmetric around the point estimate. The two critical values come from opposite tails and are not related by sign.
Width ↔ Confidence Higher confidence → wider interval. Lower confidence → narrower interval. There is no such thing as a perfect interval; you trade precision for confidence.
Sample Size Formula To achieve margin of error E at confidence level 1-α: n ≥ (z_{α/2} · σ / E)². Always round up to the next integer.

Node N8 — Section 8

Self-Assessment

Test your understanding before moving to N9:

Can you do all of these?
  • Given \(\bar{x} = 50\), \(s = 6\), \(n = 16\), construct a 95% CI for \(\mu\). [Answer: \(50 \pm 2.131 \times 6/4 = 50 \pm 3.197 = [46.803, 53.197]\).]
  • Determine whether to use z or t for the following scenarios: (a) \(n = 30\), \(\sigma = 5\) is known. (b) \(n = 10\), \(s = 3\) is calculated from data. (c) \(n = 100\), \(\sigma\) is unknown.
  • Explain why a 99% CI is wider than a 95% CI.
  • Find the minimum sample size to estimate \(\mu\) within \(E = 2\) at 99% confidence when \(\sigma = 10\). [Answer: \(n \geq (2.576 \times 10/2)^2 = 165.9\), so \(n \geq 166\).]
  • Derive a 95% CI for \(\sigma^2\) from the pivotal quantity \((n-1)S^2/\sigma^2 \sim \chi^2(n-1)\).
  • Construct a 90% CI for a proportion when 45 out of 200 trials are successes. [Answer: \(0.225 \pm 1.645\sqrt{0.225 \times 0.775/200} = [0.1763, 0.2737]\).]

High-Leverage Questions

HLQ: Exam-Style Question with Worked Solution

15 MARKS CI CONSTRUCTION MULTI-PART

A quality control engineer measures the diameters (in mm) of 12 randomly selected ball bearings from a production line. The data are assumed to come from a normal distribution. The summary statistics are: \(\bar{x} = 10.234\) and \(s = 0.187\).

(a) Construct a 95% confidence interval for the population mean \(\mu\). (4 marks)

(b) Construct a 95% confidence interval for the population variance \(\sigma^2\). (5 marks)

(c) The manufacturer claims the mean diameter is 10.300 mm. Based on your CI from part (a), is this claim plausible? Explain your reasoning. (3 marks)

(d) Suppose a second sample of 8 bearings from a different production line has \(\bar{x}_2 = 10.180\) and \(s_2 = 0.250\). Describe, without computing, how you would construct a CI for the difference in means \(\mu_1 - \mu_2\). What assumptions are needed? (3 marks)


Part (a): 95% CI for μ \(n = 12\), \(\text{d.f.} = 11\), \(t_{11, 0.025} = 2.201\).
Standard error: \(s/\sqrt{n} = 0.187/\sqrt{12} = 0.0540\).
Margin of error: \(2.201 \times 0.0540 = 0.1188\).
95% CI: \(10.234 \pm 0.1188 = [10.115,\; 10.353]\).
Part (b): 95% CI for σ2 \(\text{d.f.} = 11\), \(s^2 = 0.03497\), \((n-1)S^2 = 11 \times 0.03497 = 0.3847\).
Critical values from chi-squared tables:\ \(\chi^2_{0.025, 11} = 21.920\)\ \(\chi^2_{0.975, 11} = 3.816\)

CI for \(\sigma^2\): \(\left[\dfrac{0.3847}{21.920},\;\dfrac{0.3847}{3.816}\right] = [0.01755,\; 0.1008]\).
CI for \(\sigma\): \([\sqrt{0.01755},\;\sqrt{0.1008}] = [0.1325,\; 0.3175]\).
Part (c): Assessing the Claim The claimed value \(\mu_0 = 10.300\) is inside the 95% confidence interval [10.115, 10.353].

Therefore, at the 5% significance level, we cannot reject the claim that \(\mu = 10.300\). The data are consistent with the manufacturer's specification.
Part (d): CI for Difference of Means Method: Use the two-sample t-interval with pooled variance (assuming equal variances) or Welch's t-interval (not assuming equal variances).

Assumptions needed:
1. Both populations are normally distributed.
2. The two samples are independent.
3. For pooled variance: \(\sigma_1^2 = \sigma_2^2\) (equal variances). Check using the F-test or by comparing sample variances.

Formula (pooled):
\((\bar{x}_1 - \bar{x}_2) \pm t_{n_1+n_2-2, \alpha/2} \cdot S_p\sqrt{1/n_1 + 1/n_2}\),
where \(S_p^2 = \dfrac{(n_1-1)S_1^2 + (n_2-1)S_2^2}{n_1 + n_2 - 2}\).
Summary of answers:
(a) 95% CI for \(\mu\): [10.115, 10.353].
(b) 95% CI for \(\sigma^2\): [0.01755, 0.1008].
(c) Claim \(\mu = 10.300\) is plausible — it is inside the CI.
(d) Use two-sample t-interval with pooled variance, assuming normality, independence, and equal variances.