Let there be
successes out of
Bernoulli trials. The sample proportion is the fraction
of samples which were successes, so
|
(1)
|
For large ,
has an approximately normal
distribution. Let RE be the relative error
and SE the standard error, then
|
(2)
| |||
|
(3)
| |||
|
(4)
|
where CI is the confidence interval and is the erf
function. The number of tries needed to determine
with relative error RE and
confidence interval CI is
|
(5)
|