E = row total × column total / grand total, df = (r − 1)(c − 1)
Critical values (α = 0.05)
df 1: 3.841, 2: 5.991, 3: 7.815, 4: 9.488
Decision
reject H0 if χ² > χ²crit
2Practice problems
1.Normal distributionMedium
X is normal with mean 120 mm and standard deviation 0.3 mm; Y is independent and normal with mean 80 mm and standard deviation 0.4 mm. Find the probability P that X + Y is more than 199.3 mm. Round z to two decimals.
μX = 120, σX = 0.3μY = 80, σY = 0.4X + Y > 199.3 mm
P =
2.Normal distributionHard
The bag weights are normally distributed with mean 250 g and standard deviation 5 g. Drag the cut-off so the shaded bottom 70% is to the left of it. Find the cut-off x.
μ = 250 gσ = 5 g70%
x = g
3.Confidence intervalsMedium
A sample of 21 items has mean 107 and standard deviation s = 11. The population is roughly normal. Find the margin of error E of a 95% confidence interval for the mean.
n = 21x̄ = 107s = 1195%t(20) = 2.086
E =
4.Confidence intervalsHard
Two fertilisers are tested. Plot group 1: 11 plots, mean yield 20 kg, standard deviation 3.5 kg. Plot group 2: 20 plots, mean 29 kg, standard deviation 8 kg. Assume equal variances (pooled t, df = n₁ + n₂ − 2). Find the lower limit of the 90% confidence interval for μ₁ − μ₂.
10 employees take a typing test before and after a training course. For each person the difference d = after − before (words per minute) is recorded. The mean difference is 1.76 and the standard deviation of the differences is 6.2. Find the paired test statistic t for H₀: μd = 0.
n = 10d̄ = 1.76sd = 6.2
t =
6.Hypothesis tests & confidence intervalsHard
In a trial, 23 of 150 patients on treatment A recover, and 57 of 250 patients on treatment B. Using the pooled proportion, find the test statistic z for H₀: p₁ = p₂.
x₁ = 23n₁ = 150x₂ = 57n₂ = 250
z =
7.Linear regression & correlationMedium
The table gives 6 paired observations of x = car age in years and y = price in k€. Find Pearson's correlation coefficient r.
n = 6
r =
8.Linear regression & correlationHard
The table gives 5 paired observations of x = hours studied and y = exam score. Use the least-squares line ŷ = a + b·x. A new observation (7, 83) is made. Find its residual e = y − ŷ.
n = 5(7, 83)
e =
9.Chi-square testsMedium
The contingency table shows observed counts. Compute the chi-square statistic χ² for the test of independence between the row and column variables. Do not use a continuity correction.
N = 2202 × 2
χ² =
10.Chi-square testsHard
The table shows observed counts. Test at α = 0.01 whether the two variables are independent (no continuity correction). Compute the test statistic χ², then compare it with the critical value from the table.
N = 2003 × 2α = 0.01
χ² =
3Solutions
1.Normal distribution
Answer: P = 0.9192
Sums and differences of normal variables: if X and Y are independent and normal, X + Y and X − Y are normal too. Means add or subtract: E(X ± Y) = μX ± μY. Variances always add, also for a difference: Var(X ± Y) = σX² + σY², so σ = √(σX² + σY²). Standard deviations never add directly. The total of n independent items with the same distribution has mean n·μ and standard deviation σ·√n. Then standardise as usual: z = (x − mean)/σ and read Φ(z).
Distribution of the sum
μ = 200 mm, σ = √(0.3² + 0.4²) = 0.5 mm
Standardise
z = (199.3 − 200)/0.5 = −1.4
Upper tail
P = 1 − Φ(−1.4) = 1 − 0.08076 = 0.9192
Answer
P = 0.9192
2.Normal distribution
Answer: x = 252.6 g
From an area back to z: Φ(z) is the area to the left of z. For a left-tail area A, find z with Φ(z) = A in the table. A right-tail area A means Φ(z) = 1 − A. A central area A between −z and z leaves (1 − A)/2 in each tail, so Φ(z) = (1 + A)/2. For a value x, use x = μ + zσ.
Area to the left
Φ(z) = 0.7
z from the table
z ≈ 0.52
Back to the original units
x = 250 + 0.52·5 = 252.6 g
Answer
x = 252.6 g
3.Confidence intervals
Answer: E = 5.007
Confidence interval for a mean: x̄ ± margin of error. With a known population σ the margin is z·σ/√n; with only the sample standard deviation s, use t with n − 1 degrees of freedom: t·s/√n. Critical values: z = 1.645 (90%), 1.96 (95%), 2.576 (99%). To get a margin E or smaller, you need n ≥ (z·σ/E)², rounded up.
Critical value
df = n − 1 = 20, t = 2.086
Margin of error
E = 2.086·11/√21 = 5.007
Answer
E = 5.007
4.Confidence intervals
Answer: lower limit = −13.33 kg
Interval for a difference: estimate ± critical value × standard error. For two independent means with known σ: SE = √(σ₁²/n₁ + σ₂²/n₂) and z. With equal unknown variances: pooled s_p and t with n₁ + n₂ − 2 degrees of freedom. For paired data, work with the differences: d̄ ± t·s_d/√n.
Pooled standard deviation
sp² = (10·3.5² + 19·8²)/29 = 46.16
sp = 6.794
Margin of error
E = 1.699·6.794·√(1/11 + 1/20) = 4.333
Interval
−9 ± 4.333 → [−13.33, −4.667]
Answer
lower limit = −13.33 kg
5.Hypothesis tests & confidence intervals
Answer: t = 0.8977
Testing a mean: the test statistic measures how many standard errors the sample mean lies from the value claimed in H₀: z = (x̄ − μ₀)/(σ/√n) when σ is known, t = (x̄ − μ₀)/(s/√n) when it is estimated from the sample. A confidence interval is x̄ ± (critical value)·(standard error).
Standard error of the mean difference
SE = 6.2/√10 = 1.961
Test statistic
t = 1.76/1.961 = 0.8977
Answer
t = 0.8977
With df = 9, the two-sided 5% critical value is 2.262; |t| is smaller, so H₀ is not rejected.
6.Hypothesis tests & confidence intervals
Answer: z = −1.807
Hypothesis test: the test statistic = (estimate − value under H₀)/(standard error under H₀). The p-value is the probability, assuming H₀ is true, of a statistic at least as extreme as the one observed: the area in one tail for a one-sided H₁, twice the tail area for a two-sided H₁. Reject H₀ when p ≤ α.
Sample proportions
p̂₁ = 23/150 = 0.1533
p̂₂ = 57/250 = 0.228
p̂ = 80/400 = 0.2
Standard error under H₀
SE = √(0.2·0.8·(1/150 + 1/250)) = 0.04131
Test statistic
z = (0.1533 − 0.228)/0.04131 = −1.807
Answer
z = −1.807
|z| < 1.96, so H₀ is not rejected at the 5% level (two-sided).
7.Linear regression & correlation
Answer: r = −0.9579
Least-squares regression: with x̄ and ȳ the means, Sxx = Σ(x − x̄)², Syy = Σ(y − ȳ)² and Sxy = Σ(x − x̄)(y − ȳ), the line ŷ = a + b·x has slope b = Sxy/Sxx and intercept a = ȳ − b·x̄, so it always passes through (x̄, ȳ). Pearson's correlation coefficient r = Sxy/√(Sxx·Syy) lies between −1 and 1; r² is the fraction of the variation in y explained by the line.
Means
x̄ = 21/6 = 3.5
ȳ = 77/6 = 12.83
Sums of squares and products
Sxx = Σ(x − x̄)² = 17.5
Sxy = Σ(x − x̄)(y − ȳ) = −50.5
Syy = Σ(y − ȳ)² = 158.8
Correlation coefficient
r = −50.5/√(17.5·158.8) = −0.9579
Answer
r = −0.9579
8.Linear regression & correlation
Answer: e = −1.95
Least-squares regression: with x̄ and ȳ the means, Sxx = Σ(x − x̄)², Syy = Σ(y − ȳ)² and Sxy = Σ(x − x̄)(y − ȳ), the line ŷ = a + b·x has slope b = Sxy/Sxx and intercept a = ȳ − b·x̄, so it always passes through (x̄, ȳ). Pearson's correlation coefficient r = Sxy/√(Sxx·Syy) lies between −1 and 1; r² is the fraction of the variation in y explained by the line.
Means
x̄ = 30/5 = 6
ȳ = 394/5 = 78.8
Sums of squares and products
Sxx = Σ(x − x̄)² = 40
Sxy = Σ(x − x̄)(y − ȳ) = 246
Regression line
b = 246/40 = 6.15
a = 78.8 − 6.15·6 = 41.9
ŷ = 41.9 + 6.15·x
Predicted value
ŷ = 41.9 + 6.15·7 = 84.95
Residual
e = 83 − 84.95 = −1.95
Answer
e = −1.95
The point lies below the line.
9.Chi-square tests
Answer: χ² = 22.08
Chi-square tests: compare observed counts O with the counts E expected under H₀ using χ² = Σ(O − E)²/E. Goodness of fit: E = n·p for each category, df = k − 1 (minus one more for each parameter estimated from the data). Independence in an r × c table: E = row total × column total / grand total, df = (r − 1)(c − 1). Reject H₀ when χ² exceeds the critical value for the chosen α.
df = 1. At α = 0.05 the critical value is 3.841, so H₀ (independence) is rejected.
10.Chi-square tests
Answer: χ² = 3.6
Chi-square tests: compare observed counts O with the counts E expected under H₀ using χ² = Σ(O − E)²/E. Goodness of fit: E = n·p for each category, df = k − 1 (minus one more for each parameter estimated from the data). Independence in an r × c table: E = row total × column total / grand total, df = (r − 1)(c − 1). Reject H₀ when χ² exceeds the critical value for the chosen α.