For p = 0.20 and n = 400, compute SE(p̂) = √(p(1 − p)/n) and P(p̂ > 0.23).
For p = 0.20 and n = 400, compute SE(p̂) = √(p(1 − p)/n) and P(p̂ > 0.23).
Answer
import math def phi(z): return 0.5 * (1 + math.erf(z / math.sqrt(2))) p, n = 0.20, 400 se = math.sqrt(p * (1 - p) / n) above = 1 - phi((0.23 - p) / se) print(f"SE={se:.4f} P(phat>0.23)={above:.4f}")
IBS1 §7.3 (the sampling distribution of the proportion — written p′ there, p̂ here), IS1 §7.3, CC BY 4.0 — shape only; original dataset