= Solution
For a fixed true parameter $0<p<1$, the usual <asymptotic normality of a maximum likelihood estimator>[asymptotic normality of maximum likelihood estimators] gives
$$
\sqrt n(\widehat p-p)\ \xrightarrow{d}\ N\!\left(0,\frac{p^2(1-p)}r\right).
$$
Equivalently, for a large sample, $\widehat p$ is approximately <normally distributed> with mean $p$ and <variance> $p^2(1-p)/(nr)$. Replacing the unknown <variance> by its consistent plug-in estimate gives the <Wald confidence interval>
$$
\boxed{\widehat p\ \pm\ z_{1-\alpha/2}\widehat p\sqrt{\frac{1-\widehat p}{nr}}}.
$$
Here $z_{1-\alpha/2}$ is a standard-normal <quantile>. Intersect with the physical parameter range $(0,1)$ if needed. This is an interior, large-sample approximation; the degenerate estimate $\widehat p=1$ from $S=0$ does not justify a zero-width finite-sample <interval>.
Back to article page