SME
Grade 12 Math · Problem type
Two-proportion z-test
Use this for “84 of 150 people sent a reminder voted, against 66 of 150 who were not. Is there a difference?”
Chart
The curve is centered at μ = 0 with standard error SE = 0.05774.
d = 0.12 is 2.0785 standard deviations above the mean: z = 2.0785.
Red outline: the rejection region, area α = 0.05, past z = −1.96 and z = 1.96.
Test statistic z = 2.0785.
Amber: the p-value, 0.0377 < α = 0.05: reject H₀.
This is an example. Type your own values to start a new problem.
d
=
k₁
n₁
−
k₂
n₂
p̂
=
+
+
z
=
d
SE
P
p-value
worked out (not typed)
α
Significance level
example
Formulas
d
=
k₁
n₁
−
k₂
n₂
0.12
=
84
150
−
66
150
p̂
=
k₁
+
k₂
n₁
+
n₂
0.5
=
84 + 66
150 + 150
SE
=
√(
p̂
×
(1
−
p̂
)
×
(
1
n₁
+
1
n₂
))
0.05774
=
√(0.5
×
(1
−
0.5)
×
(
1
150
+
1
150
))
z
=
d
SE
2.0785
=
0.12
0.05774
P
=
2
×
(1
−
Φ(|
z
|))
0.03767 = 2 × (1 − Φ(|2.0785|))
Assumptions
•
Two independent random samples, or two groups assigned at random; H₀: p₁ = p₂, Hₐ: p₁ ≠ p₂.
•
If H₀ is true both samples share one proportion: pool them, p̂ = (k₁ + k₂) ÷ (n₁ + n₂).
•
Each sample has at least 10 successes and 10 failures, so the difference is close to normal.
Step-by-step
WE KNOW
k₁ = 84, n₁ = 150, k₂ = 66, n₂ = 150, α = 0.05
FIND
difference of the proportions, p̂₁ − p̂₂ (d), pooled proportion (p̂), standard error if H₀ is true (SE), test statistic (z), p-value (P)
Step 1 · Find difference of the proportions, p̂₁ − p̂₂ (d)
Use d = k₁ ÷ n₁ − k₂ ÷ n₂
Each sample’s proportion of successes, p̂₁ − p̂₂.
d
=
84
150
−
66
150
0.56 − 0.44 = 0.12
d
=
0.12
Step 2 · Find pooled proportion (p̂)
Use p̂ = (k₁ + k₂) ÷ (n₁ + n₂)
If H₀ is true the two samples share one proportion: all the successes over everyone.
p̂
=
84 + 66
150 + 150
p̂
=
150
300
p̂
=
0.5
Step 3 · Find standard error if H₀ is true (SE)
Use SE = √(p̂ × (1 − p̂) × (1 ÷ n₁ + 1 ÷ n₂))
The spread of p̂₁ − p̂₂ if H₀ is true, from the pooled proportion.
SE
=
√(0.5
×
(1
−
0.5)
×
(
1
150
+
1
150
))
SE = √(0.5 × 0.5 × (0.0066667 + 0.0066667))
SE
=
√
0.5 × 0.5 × 0.013333
SE
=
√
0.25 × 0.013333
SE
=
√
0.0033332
SE = 0.057735
Step 4 · Find test statistic (z)
Use z = d ÷ SE
H₀ says the difference is 0: count how many standard errors it is from 0.
z
=
0.12
0.057735
z
=
2.0785
Step 5 · Find p-value (P)
Use P = 2 × (1 − Φ(|z|))
Hₐ
says
“not
equal”,
so
both
tails
past
|
z
|
count
as
at
least
as
extreme.
P
=
2
×
(1
−
Φ(|2.0785|))
P
=
0.03767
→
0.03767
<
α
=
0.05:
reject
H₀
Check
Put the numbers back in. Both sides should match.
0.12
=
84
150
−
66
150
✓
0.5
=
84 + 66
150 + 150
✓
0.057735
≈
√(0.5
×
(1
−
0.5)
×
(
1
150
+
1
150
))
✓
2.0785
≈
0.12
0.057735
✓
0.03767 = 2 × (1 − Φ(|2.0785|)) ✓
Topic check
See what you know: 5 questions on this topic
New questions each time. Pass to mark it complete.
Refresh
Related lessons
Hypothesis tests for one and two samples
Main lesson
One-mean z-test
Use this for “Is the mean less than μ₀?” (or more than, or different from) with σ known.
One-mean t-test
Use this for “A sample of 16 has mean 496 g and s = 8 g. Is the mean different from 500 g?”
Matched pairs t-test
Use this for “Twelve students gained 2.5 points on average after a review, s = 3.2. Did the review change scores?”
Two-sample t-test for means
Use this for “Do two groups have different means?” from two independent samples.
Which alternative hypothesis?
Use this for “Write H₀ and Hₐ for the claim that the new bulbs last longer.”
Type I or Type II error?
Use this for “Name a Type I and a Type II error for this test.”