epi.ssstrataestb  R Documentation 
Sample size to estimate a binary outcome using stratified random sampling.
epi.ssstrataestb(strata.n, strata.Py, epsilon, error = "relative",
nfractional = FALSE, conf.level = 0.95)
strata.n 
vector of integers, the number of individual listing units in each strata. 
strata.Py 
vector of numbers, the expected proportion of individual listing units with the outcome of interest for each strata. 
epsilon 
scalar number, the maximum difference between the estimate and the unknown population value expressed in absolute or relative terms. 
error 
character string. Options are 
nfractional 
logical, return fractional sample size. 
conf.level 
scalar number, the level of confidence in the computed result. 
A list containing the following:
strata.sample 
the estimated sample size for each strata. 
strata.total 
the estimated total size. 
strata.stats 

Mark Stevenson (Faculty of Veterinary and Agricultural Sciences, The University of Melbourne, Australia).
Javier Sanchez (Atlantic Veterinary College, University of Prince Edward Island, Charlottetown Prince Edward Island, C1A 4P3, Canada).
Levy PS, Lemeshow S (1999). Sampling of Populations Methods and Applications. Wiley Series in Probability and Statistics, London, pp. 175  179.
## EXAMPLE 1:
## Dairies are to be sampled to determine the proportion of herd managers
## using foot bathes. Herds are stratified according to size (small, medium,
## and large). The number of herds in each strata are 1500, 2500, and 4000
## (respectively). A review of the literature indicates that use of foot bathes
## on farms is in the order of 0.50, with the probability of usage increasing
## as herds get larger. How many dairies should be sampled?
strata.n < c(1500, 2500, 4000)
strata.Py < c(0.50, 0.60, 0.70)
epi.ssstrataestb(strata.n, strata.Py, epsilon = 0.20, error = "relative",
nfractional = FALSE, conf.level = 0.95)
## A total of 55 herds should be sampled: 11 small, 18 medium, and 28 large.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.