powered by
Calculates Agresti-Coull confidence limits for a simple proportion (apparent prevalence)
binom.agresti(x, n, conf = 0.95)
number of positives in sample
sample size, note: either x or n can be a vector, but at least one must be scalar
level of confidence required, default 0.95 (scalar)
a dataframe with 6 columns, x, n, proportion, lower confidence limit, upper confidence limit, confidence level and CI method
# NOT RUN { # test binom.agresti binom.agresti(25, 200) binom.agresti(seq(10, 100, 10), 200) binom.agresti(50, seq(100, 1000, 100)) # }
Run the code above in your browser using DataLab