R/statpsych3.R
size.ci.prop.ps.Rd
Computes the sample size required to estimate a population proportion difference with desired confidence interval precision in a paired-samples design. Set the proportion planning values to .5 for a conservatively large sample size. Set the phi correlation planning value to the smallest value within a plausible range for a conservatively large sample size.
size.ci.prop.ps(alpha, p1, p2, phi, w)
alpha level for 1-alpha confidence
planning value of proportion for measurement 1
planning value of proportion for measurement 2
planning value of phi correlation
desired confidence interval width
Returns the required sample size
size.ci.prop.ps(.05, .2, .3, .8, .1)
#> Sample size
#> 118
# Should return:
# Sample size
# 118