Statistics 2: Statistical Inference: cram pack

Formula sheets, the key method steps for every topic and 10 practice problems, with full solutions at the back.

New problemsBack to the course

In the print window, choose “Save as PDF” to keep a copy on your device.

1Formulas and methods

Normal distribution

z-score
z = (x − μ)/σ
Below x
P(X < x) = Φ(z)
Above x
P(X > x) = 1 − Φ(z)
Between
Φ(z2) − Φ(z1)
Percentile
x = μ + z·σ

Method

  1. Convert the value to a z-score: z = (x − μ)/σ.
  2. Look up Φ(z), the area to the left of z.
  3. For the area to the right use 1 − Φ(z); for an interval subtract the two left areas.
  4. For a percentile, work backwards: find z for the area, then x = μ + z·σ.

Confidence intervals

σ known
x̄ ± z·σ/√n
σ unknown
x̄ ± t·s/√n, df = n − 1
Critical z
90%: 1.645, 95%: 1.96, 99%: 2.576
Sample size
n = (z·σ/E)², rounded up

Method

  1. Decide between z (population σ known) and t (only the sample s, with n − 1 degrees of freedom).
  2. Find the critical value for the confidence level.
  3. Margin of error: E = critical value × standard deviation/√n.
  4. Interval: x̄ ± E.

Hypothesis tests & confidence intervals

z-test for a mean
z = (x̄ − μ0)/(σ/√n)
t-test for a mean
t = (x̄ − μ0)/(s/√n), df = n − 1
Two-sided at 5%
reject H0 if |z| > 1.96
Confidence interval
x̄ ± z·σ/√n

Method

  1. State H₀ and H₁ and decide whether the test is one- or two-sided.
  2. Calculate the test statistic: (x̄ − μ₀)/(σ/√n), or with s and t.
  3. Compare with the critical value, or find the p-value.
  4. Reject H₀ if the statistic is beyond the critical value (p below α), and state the conclusion in words.

Linear regression & correlation

Sums of squares
Sxx = Σ(x − x̄)² = Σx² − (Σx)²/n, Sxy = Σxy − ΣxΣy/n
Slope
b = Sxy/Sxx
Intercept
a = ȳ − b·x̄
Correlation
r = Sxy/√(SxxSyy)
Residual
e = y − ŷ

Chi-square tests

Test statistic
χ² = Σ(O − E)²/E
Goodness of fit
E = n·p, df = k − 1 − (estimated parameters)
Independence
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
70.75122.5P = ?

The IQ scores are normally distributed with mean 100 points and standard deviation 15 points. What fraction lies between 70.75 and 122.5 points? Give P as a decimal.

μ = 100σ = 15x1 = 70.75x2 = 122.5
P =
2.Normal distributionHard
157164171178185192199cmtop 30%

The heights of adult men are normally distributed with mean 178 cm and standard deviation 7 cm. Drag the cut-off so the shaded top 30% is to the right of it. Find the cut-off x.

μ = 178 cmσ = 7 cm30%
x = cm
3.Confidence intervalsMedium
n = 15, sd​ = 7.80L = ?Ud̄ = 5.6E95%

The blood pressure of 15 patients is measured before and after a treatment. The differences d = before − after (mmHg) have mean 5.6 and standard deviation 7.8. Find the lower limit of the 95% confidence interval for the mean difference.

n = 15d̄ = 5.6sd = 7.895%t(14) = 2.145
lower limit = mmHg
4.Confidence intervalsHard
μ₁ − μ₂, t(19) = 2.8610L = ?Ux̄₁ − x̄₂E99%

Two fertilisers are tested. Plot group 1: 7 plots, mean yield 66.5 kg, standard deviation 8.5 kg. Plot group 2: 14 plots, mean 78 kg, standard deviation 10 kg. Assume equal variances (pooled t, df = n₁ + n₂ − 2). Find the lower limit of the 99% confidence interval for μ₁ − μ₂.

n₁ = 7x̄₁ = 66.5s₁ = 8.5n₂ = 14x̄₂ = 78s₂ = 1099%t(19) = 2.861
lower limit = kg
5.Hypothesis tests & confidence intervalsMedium
t −1.98401.984

A sample of 100 students has a mean score of 197.9 and a sample standard deviation of 15. Find the test statistic t for H₀: μ = 200.

μ₀ = 200x̄ = 197.9s = 15n = 100
t =
6.Hypothesis tests & confidence intervalsHard
σ = 10, n = ?x̄ − Ex̄ + Ex̄E = 399%

How large must a sample be so that the 99% confidence interval for a mean has a margin of error of at most 3? The standard deviation is 10. Find the smallest sample size n.

σ = 10E = 399%
n =
7.Linear regression & correlationMedium
xy1423515707769881198xy510406080100

The table gives 6 paired observations of x = hours studied and y = exam score. Find the coefficient of determination r² of the least-squares line.

n = 6
r² =
8.Linear regression & correlationHard
xy35155576697211781385xy5106080x = 4

The table gives 6 paired observations of x = hours studied and y = exam score. Use the least-squares line ŷ = a + b·x. A new observation (4, 58) is made. Find its residual e = y − ŷ.

n = 6(4, 58)
e =
9.Chi-square testsMedium
coughno coughTotalsmokers5050100non-smokers63440Total5684140

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 = 1402 × 2
χ² =
10.Chi-square testsHard
passfailTotalline 15743100line 2132740line 3202040Total9090180dfα = 0.05α = 0.0113.8416.63525.9919.21037.81511.34549.48813.277511.07015.086612.59216.812714.06718.475815.50720.090916.91921.6661018.30723.209

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 = 1803 × 2α = 0.01
χ² =

3Solutions

1.Normal distribution

Answer: P = 0.9076

Normal distribution: convert a value x to a z-score, z = (x − μ)/σ, which counts standard deviations from the mean. A z-table (or Φ(z)) gives the area to the left of z, which is P(X < x). The area to the right is 1 − Φ(z), and the area between two values is the difference of their two areas.

z-scores

z₁ = (70.75 − 100)/15 = −1.95
z₂ = (122.5 − 100)/15 = 1.5

Area between

P = Φ(1.5) − Φ(−1.95) = 0.9332 − 0.02559 = 0.9076

Answer

P = 0.9076
2.Normal distribution

Answer: x = 181.6 cm

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 = 178 + 0.52·7 = 181.6 cm

Answer

x = 181.6 cm
3.Confidence intervals

Answer: lower limit = 1.28 mmHg

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.

Critical value

df = 14, t = 2.145

Margin of error

E = 2.145·7.8/√15 = 4.32

Interval

5.6 ± 4.32 → [1.28, 9.92]

Answer

lower limit = 1.28 mmHg
4.Confidence intervals

Answer: lower limit = −24.15 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² = (6·8.5² + 13·10²)/19 = 91.24
sp = 9.552

Margin of error

E = 2.861·9.552·√(1/7 + 1/14) = 12.65

Interval

−11.5 ± 12.65 → [−24.15, 1.15]

Answer

lower limit = −24.15 kg
5.Hypothesis tests & confidence intervals

Answer: t = −1.4

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

SE = 15/√100 = 15/10 = 1.5

Test statistic

t = (197.9 − 200)/1.5 = −1.4

Answer

t = −1.4
t0.025; df = 99 = 1.984

|t| < 1.984, so H₀ is not rejected at the 5% level (two-sided).

6.Hypothesis tests & confidence intervals

Answer: n = 74

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).

Solve for n

n = (2.576·10/3)² = 73.73

Round up

n = 74

Answer

n = 74
7.Linear regression & correlation

Answer: r² = 0.9854

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̄ = 36/6 = 6
ȳ = 425/6 = 70.83

Sums of squares and products

Sxx = Σ(x − x̄)² = 70
Sxy = Σ(x − x̄)(y − ȳ) = 397
Syy = Σ(y − ȳ)² = 2285

Coefficient of determination

r² = 397²/(70·2285) = 0.9854

Answer

r² = 0.9854

About 98.54% of the variation in y is explained by the line.

8.Linear regression & correlation

Answer: e = 4.167

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̄ = 48/6 = 8
ȳ = 407/6 = 67.83

Sums of squares and products

Sxx = Σ(x − x̄)² = 70
Sxy = Σ(x − x̄)(y − ȳ) = 245

Regression line

b = 245/70 = 3.5
a = 67.83 − 3.5·8 = 39.83
ŷ = 39.83 + 3.5·x

Predicted value

ŷ = 39.83 + 3.5·4 = 53.83

Residual

e = 58 − 53.83 = 4.167

Answer

e = 4.167

The point lies above the line.

9.Chi-square tests

Answer: χ² = 14.58

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 α.

Expected counts

smokers: 100·56/140 = 40, 100·84/140 = 60
non-smokers: 40·56/140 = 16, 40·84/140 = 24

Chi-square statistic

χ² = (50 − 40)²/40 + (50 − 60)²/60 + (6 − 16)²/16 + (34 − 24)²/24
χ² = 14.58

Answer

χ² = 14.58

df = 1. At α = 0.05 the critical value is 3.841, so H₀ (independence) is rejected.

10.Chi-square tests

Answer: χ² = 6.86

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 α.

Expected counts

line 1: 50, 50
line 2: 20, 20
line 3: 20, 20

Chi-square statistic

χ² = (57 − 50)²/50 + (43 − 50)²/50 + (13 − 20)²/20 + (27 − 20)²/20 + (20 − 20)²/20 + (20 − 20)²/20
χ² = 6.86

Decision

df = 2, χ²crit = 9.210
6.86 < 9.210

Answer

χ² = 6.86

χ² is below the critical value, so H₀ is not rejected: there is no significant evidence of a relationship.

ExamProblems · examproblems.com/courses/statistics-2-inference