Computes the sample size required to estimate a population proportion with desired confidence interval precision. Set the proportion planning value to .5 for a conservatively large sample size.
size.ci.prop(alpha, p, w)
alpha level for 1-alpha confidence
planning value of proportion
desired confidence interval width
Returns the required sample size
size.ci.prop(.05, .4, .2)
#> Sample size
#> 93
# Should return:
# Sample size
# 93