Yesterday (6a): the normal model gave us a math shortcut for hypothesis tests on a proportion.
Check conditions → the sampling distribution of \(\hat{p}\) is roughly normal
Standardize \(\hat{p}\) to a \(Z\)-score → read the p-value as a tail area
Today: the same normal model gives us a math shortcut for confidence intervals.
Recall: The Bootstrap CI
Back in 4 we built a 95% CI by:
Resampling the original sample many times (with replacement)
Computing \(\hat{p}\) for each resample → bootstrap distribution
Reading off the 2.5th and 97.5th percentiles
Because the bootstrap distribution was approximately normal and centered at \(\hat{p}\), those 2.5th and 97.5th percentiles fall close to \(\hat{p} \pm 1.96 \cdot SE\) — and that’s the formula we’ll use today.
CI Formula via the Normal Model
If the sampling distribution of \(\hat{p}\) is approximately normal, the confidence interval is:
\[\hat{p} \;\pm\; z^* \cdot SE\]
where:
\(\hat{p}\) — the observed proportion
\(z^*\) — critical value (multiplier) for the chosen confidence level
\(SE = \sqrt{\dfrac{\hat{p}\,(1-\hat{p})}{n}}\)
Conditions: CI for One Proportion
Before using the normal model for a CI, check:
Independence — observations are independent (random sample, sample < 10% of population)
Key difference from H-test: a CI plugs in \(\hat{p}\); an H-test plugs in \(p_0\). A CI has no null value to assume.
Critical Values: z*
Confidence level
\(z^*\)
90%
1.645
95%
1.960
99%
2.576
These come straight from the standard normal:
95% confident → capture the middle 95% of the standard normal → 2.5% left in each tail → \(z^*\) is the value with 2.5% above it, 1.96.
The Model-Based Inference calculator in Jamovi’s Randomize module gives you \(z^*\) for any confidence level (90%, 92%, 99%, …) — not just the three above. It also computes the CI and p-value directly.
Margin of Error = Dart Radius
Back in 4a: each \(\hat{p}\) is a dart, \(p\) is the bullseye. The CI is a circle around our dart, sized to catch the bullseye some fraction of the time.
The margin of error is the radius of that circle:
\[\text{margin of error} \;=\; z^* \cdot SE\]
So the CI is just \(\hat{p} \;\pm\;\) margin of error.
Whatever makes the radius bigger makes the CI wider — next slide names what controls it.
We are 95% confident that the true proportion of payday borrowers who support the regulation is between 47.9% and 54.7%.
Notice: the interval includes 0.5 — the null value from yesterday’s hypothesis test. That’s consistent with our H-test result (we failed to reject \(H_0: p = 0.5\)). Topic 7 will tighten this “consistent with” into a precise equivalence.
Build CIs at Different Levels
A campus survey of \(n = 400\) randomly sampled university students asks whether they’ve used a generative-AI tool for a class assignment. 272 say yes (\(\hat{p} = 0.68\)). Conditions are met (272 ≥ 10 successes, 128 ≥ 10 failures).
Compute SE, then build the 95% CI.\(SE = \sqrt{\dfrac{0.68 \times 0.32}{400}} \approx 0.0233\). 95% CI:\(0.68 \pm 1.96 \times 0.0233 \approx\)\((0.634,\; 0.726)\).
Interpret the 95% CI in plain English.We are 95% confident that the true proportion of university students who have used a generative-AI tool for a class assignment is between 63.4% and 72.6%.
Now build the 99% CI.(use \(z^* = 2.576\))\(0.68 \pm 2.576 \times 0.0233 \approx\)\((0.620,\; 0.740)\) — wider, as the formula predicts.
Without computing, will the 90% CI be wider or narrower than the 95%? Why?Narrower.\(z^*\) drops from 1.96 to 1.645, so the margin of error shrinks. Less confidence required → smaller circle around our dart.
When Does the Normal Model Work?
Blue bars = simulated sampling distribution. Red curve = normal approximation.
Left (\(n=100\), \(p=0.5\)): success-failure passes (\(np = 50\), \(n(1-p) = 50\)) — great fit.
Right (\(n=30\), \(p=0.05\)): success-failure fails (\(np = 1.5 < 10\)) — true distribution is right-skewed, normal model misses it. That’s why we check the conditions.
Simulation or Normal Model?
For each scenario, you want a 95% CI for \(p\). Which approach should you use — simulation or the normal model?
Random sample of \(n = 1{,}200\) likely voters; \(\hat{p} = 0.52\). Normal model. Observed successes \(\approx 624\) and failures \(\approx 576\) — both far above 10. Conditions met, so use the formula.
Pilot trial of \(n = 25\) patients on a new pain medication; 5 report substantial relief (\(\hat{p} = 0.20\)). Simulation. Only 5 observed successes — fails success-failure. Use the bootstrap percentile CI from Topic 4.
Quality-control sample of \(n = 200\) widgets; 3 are defective (\(\hat{p} = 0.015\)). Simulation. Only 3 observed successes — fails success-failure (rare events even at moderate \(n\)). Use the bootstrap percentile CI from Topic 4.
Summary
CI from the normal model:\(\;\hat{p} \pm z^* \cdot SE\), with \(SE = \sqrt{\hat{p}(1-\hat{p})/n}\).
Conditions to check:
Independence
\(n\hat{p} \geq 10\) and \(n(1-\hat{p}) \geq 10\) — at least 10 successes and 10 failures observed
When both conditions hold: simulation and the normal model give similar answers, and the formula is faster. Success-failure fails (independence OK): fall back on the bootstrap. Independence fails: both methods break down — the data themselves need a closer look.