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
850 kg887.9 kgT = X₁ + … + X₁₀?

The masses of passengers with luggage are independent and normal with mean 85 kg and standard deviation 12 kg. Find the probability P that the total mass of 10 of them is below 887.9 kg. Round z to two decimals.

μ = 85 kgσ = 12 kgn = 10< 887.9 kg
P =
2.Normal distributionHard
μ = 65x = ?97.5%

The exam scores are normally distributed with mean 65 points and standard deviation 10 points. Find the value x below which 97.5% of them lie (the 97.5th percentile).

μ = 65σ = 10P = 97.5%
x = points
3.Confidence intervalsMedium
n = 10, s = 17.5L = ?Ux̄ = 64E90%

A sample of 10 items has mean 64 and standard deviation s = 17.5. The population is roughly normal. Find the lower limit of the 90% confidence interval for the mean.

n = 10x̄ = 64s = 17.590%t(9) = 1.833
lower limit =
4.Confidence intervalsHard
n = 20Lσ = ?s = 8.895%

The diameters of 20 machined shafts have a sample standard deviation of 8.8 µm. Assuming the diameters are normally distributed, find the upper limit σ of the 95% confidence interval for the population standard deviation. With df = 19, 2.5% of the χ² distribution lies below 8.907 and 2.5% lies above 32.852.

n = 20s = 8.8 µmχ² = 8.907, 32.852
σ = µm
5.Hypothesis tests & confidence intervalsMedium
t −2.06402.064

A sample of 25 students has a mean score of 500.7 and a sample standard deviation of 5. Find the test statistic t for H₀: μ = 500.

μ₀ = 500x̄ = 500.7s = 5n = 25
t =
6.Hypothesis tests & confidence intervalsHard
z −2.57602.576

A sample of 16 measurements has mean 75.1. The population standard deviation is 5. Find the upper limit U of the 99% confidence interval for the mean.

x̄ = 75.1σ = 5n = 1699%
U =
7.Linear regression & correlationMedium
xy18842092221042411526119xy2025100120

The table gives 5 paired observations of x = temperature in °C and y = ice creams sold. Their sums are given. Find Pearson's correlation coefficient r from these sums.

n = 5Σx = 110Σy = 514Σx² = 2460Σy² = 53722Σxy = 11494
r =
8.Linear regression & correlationHard
xy128225322421521xy2425ŷ = 24

The table gives 5 paired observations of x = car age in years and y = price in k€. Use the least-squares line ŷ = a + b·x. For which value x does the line predict ŷ = 24?

n = 5ŷ = 24
x =
9.Chi-square testsMedium
yesnoTotalmen384280women8812100Total12654180

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 = 1802 × 2
χ² =
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 goodness-of-fit test compares observed counts in 9 categories with fully specified expected proportions (no parameters are estimated from the data). Using the table, find the critical value χ²crit at significance level α = 0.01.

α = 0.01
χ²crit =

3Solutions

1.Normal distribution

Answer: P = 0.8413

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 = 850 kg, σT = 12·√10 = 37.95 kg

Standardise

z = (887.9 − 850)/37.95 = 1

Probability

P = Φ(1) = 0.8413

Answer

P = 0.8413
2.Normal distribution

Answer: x = 84.6 points

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 for the percentile

Φ(z) = 0.975 → z = 1.96

Back to x

x = 65 + 1.96·10 = 84.6 points

Answer

x = 84.6 points
3.Confidence intervals

Answer: lower limit = 53.86

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 = 9, t = 1.833

Margin of error

E = 1.833·17.5/√10 = 10.14

Interval

64 ± 10.14 → [53.86, 74.14]

Answer

lower limit = 53.86
4.Confidence intervals

Answer: σ = 12.85 µm

Interval for a variance: (n − 1)s²/σ² has a χ² distribution with n − 1 degrees of freedom. The 95% interval for σ² runs from (n − 1)s² divided by the upper χ² value (2.5% above it) to (n − 1)s² divided by the lower χ² value (2.5% below it); the interval for σ is the square root of both limits. It is not symmetric around s.

Sum of squares

(n − 1)s² = 19·8.8² = 1471

Limits for σ²

1471/32.852 = 44.79
1471/8.907 = 165.2

Limit for σ

σ = √165.2 = 12.85 µm

Answer

σ = 12.85 µm

95% interval for σ: [6.692, 12.85] µm.

5.Hypothesis tests & confidence intervals

Answer: t = 0.7

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 = 5/√25 = 5/5 = 1

Test statistic

t = (500.7 − 500)/1 = 0.7

Answer

t = 0.7
t0.025; df = 24 = 2.064

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

6.Hypothesis tests & confidence intervals

Answer: U = 78.32

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

Margin of error

E = 2.576·5/√16 = 3.22

Interval limit

U = 75.1 + 3.22 = 78.32

Answer

U = 78.32
7.Linear regression & correlation

Answer: r = 0.9898

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 = 11494 − 110·514/5 = 186
Sxx = 2460 − 110²/5 = 40
Syy = 53722 − 514²/5 = 882.8

Correlation coefficient

r = 186/√(40·882.8) = 0.9898

Answer

r = 0.9898
8.Linear regression & correlation

Answer: x = 2.667

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̄ = 15/5 = 3
ȳ = 117/5 = 23.4

Sums of squares and products

Sxx = Σ(x − x̄)² = 10
Sxy = Σ(x − x̄)(y − ȳ) = −18

Regression line

b = −18/10 = −1.8
a = 23.4 − (−1.8)·3 = 28.8
ŷ = 28.8 − 1.8·x

Solve for x

x = (24 − 28.8)/(−1.8) = 2.667

Answer

x = 2.667
9.Chi-square tests

Answer: χ² = 34.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 counts

men: 80·126/180 = 56, 80·54/180 = 24
women: 100·126/180 = 70, 100·54/180 = 30

Chi-square statistic

χ² = (38 − 56)²/56 + (42 − 24)²/24 + (88 − 70)²/70 + (12 − 30)²/30
χ² = 34.71

Answer

χ² = 34.71

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

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 = 9 − 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