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
96 kg100.5 kgT = X₁ + … + X₈?

The masses of boxes are independent and normal with mean 12 kg and standard deviation 0.8 kg. Find the probability P that the total mass of 8 of them exceeds 100.5 kg. Round z to two decimals.

μ = 12 kgσ = 0.8 kgn = 8> 100.5 kg
P =
2.Normal distributionHard
4 s0X − Y?

Runner A's lap time X and runner B's lap time Y are independent and normal: X has mean 52 s and standard deviation 4 s, Y has mean 48 s and standard deviation 3 s. Find the probability P that X is greater than Y. Round z to two decimals.

μX = 52 s, σX = 4 sμY = 48 s, σY = 3 s
P =
3.Confidence intervalsMedium
n = 13, sd​ = 7.40LU = ?d̄ = −3E90%

The blood pressure of 13 patients is measured before and after a treatment. The differences d = before − after (mmHg) have mean −3 and standard deviation 7.4. Find the upper limit of the 90% confidence interval for the mean difference.

n = 13d̄ = −3sd = 7.490%t(12) = 1.782
upper limit = mmHg
4.Confidence intervalsHard
μ₁ − μ₂, t(29) = 2.0450L = ?Ux̄₁ − x̄₂E95%

Two fertilisers are tested. Plot group 1: 20 plots, mean yield 81 kg, standard deviation 6 kg. Plot group 2: 11 plots, mean 82.5 kg, standard deviation 1 kg. Assume equal variances (pooled t, df = n₁ + n₂ − 2). Find the lower limit of the 95% confidence interval for μ₁ − μ₂.

n₁ = 20x̄₁ = 81s₁ = 6n₂ = 11x̄₂ = 82.5s₂ = 195%t(29) = 2.045
lower limit = kg
5.Hypothesis tests & confidence intervalsMedium
−2.3062.306t = ?df = 8

9 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 2 and the standard deviation of the differences is 2. Find the paired test statistic t for H₀: μd = 0.

n = 9d̄ = 2sd = 2
t =
6.Hypothesis tests & confidence intervalsHard
σ = 12, n = ?x̄ − Ex̄ + Ex̄E = 199%

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

σ = 12E = 199%
n =
7.Linear regression & correlationMedium
xy254146168241029xy510102030

The table gives 5 paired observations of x = load in kN and y = extension in mm. Their sums are given. Find Pearson's correlation coefficient r from these sums.

n = 5Σx = 30Σy = 88Σx² = 220Σy² = 1894Σxy = 644
r =
8.Linear regression & correlationHard
xy1553185921732490279230108xy152025306080100ŷ = 80

The table gives 6 paired observations of x = temperature in °C and y = ice creams sold. Use the least-squares line ŷ = a + b·x. For which value x does the line predict ŷ = 80?

n = 6ŷ = 80
x =
9.Chi-square testsMedium
busbikecarTotalstudents22161957staff28252477Total504143134

The contingency table shows observed counts. For a chi-square test of independence, find the expected count E for the cell “staff, car”.

row total = 77column total = 43N = 134
E =
10.Chi-square testsHard
dfα = 0.05α = 0.0113.8416.63525.9919.21037.81511.34549.48813.277511.07015.086612.59216.812714.06718.475815.50720.090916.91921.6661018.30723.209

A chi-square test of independence is carried out on a contingency table with 3 rows and 5 columns (not counting the totals). Using the table, find the critical value χ²crit at significance level α = 0.01.

α = 0.01
χ²crit =

3Solutions

1.Normal distribution

Answer: P = 0.0233

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 total

μT = 96 kg, σT = 0.8·√8 = 2.263 kg

Standardise

z = (100.5 − 96)/2.263 = 1.99

Probability

P = 1 − Φ(1.99) = 0.0233

Answer

P = 0.0233
2.Normal distribution

Answer: P = 0.7881

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 difference

μ = 52 − 48 = 4 s, σ = 5 s

Standardise

z = (0 − 4)/5 = −0.8

Probability

P = 1 − Φ(−0.8) = 0.7881

Answer

P = 0.7881
3.Confidence intervals

Answer: upper limit = 0.6574 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 = 12, t = 1.782

Margin of error

E = 1.782·7.4/√13 = 3.657

Interval

−3 ± 3.657 → [−6.657, 0.6574]

Answer

upper limit = 0.6574 mmHg
4.Confidence intervals

Answer: lower limit = −5.255 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² = (19·6² + 10·1²)/29 = 23.93
sp = 4.892

Margin of error

E = 2.045·4.892·√(1/20 + 1/11) = 3.755

Interval

−1.5 ± 3.755 → [−5.255, 2.255]

Answer

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

Answer: t = 3

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 = 2/√9 = 0.6667

Test statistic

t = 2/0.6667 = 3

Answer

t = 3

With df = 8, the two-sided 5% critical value is 2.306; |t| is larger, so H₀ is rejected.

6.Hypothesis tests & confidence intervals

Answer: n = 956

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·12/1)² = 955.6

Round up

n = 956

Answer

n = 956
7.Linear regression & correlation

Answer: r = 0.9872

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.

Centred sums

Sxy = 644 − 30·88/5 = 116
Sxx = 220 − 30²/5 = 40
Syy = 1894 − 88²/5 = 345.2

Correlation coefficient

r = 116/√(40·345.2) = 0.9872

Answer

r = 0.9872
8.Linear regression & correlation

Answer: x = 22.72

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̄ = 135/6 = 22.5
ȳ = 475/6 = 79.17

Sums of squares and products

Sxx = Σ(x − x̄)² = 157.5
Sxy = Σ(x − x̄)(y − ȳ) = 586.5

Regression line

b = 586.5/157.5 = 3.724
a = 79.17 − 3.724·22.5 = −4.619
ŷ = −4.619 + 3.724·x

Solve for x

x = (80 − (−4.619))/3.724 = 22.72

Answer

x = 22.72
9.Chi-square tests

Answer: E = 24.71

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 count

E = 77·43/134 = 24.71

Answer

E = 24.71
10.Chi-square tests

Answer: χ²crit = 20.09

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

Degrees of freedom

df = (3 − 1)·(5 − 1) = 8

Table

χ²crit(df = 8, α = 0.01) = 20.090

Answer

χ²crit = 20.090

Reject H₀ if the computed χ² is larger than this value.

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