Sample size for pooled testing for freedom

Share:

Description

Calculates sample size to achieve desired population-level sensitivity, assuming pooled sampling and allowing for imperfect sensitivity and specificity of the pooled test

Usage

1
n.pooled(sep, k, pstar, pse, psp = 1)

Arguments

sep

desired population sensitivity (scalar or vector)

k

pool size (constant across pools) (scalar or vector of same length as sep)

pstar

design prevalence (scalar or vector of same length as sep)

pse

pool-level sensitivity (scalar or vector of same length as sep)

psp

pool-level specificity (scalar or vector of same length as sep)

Value

vector of sample sizes

Examples

1
2
3
4
# examples for n.pooled
n.pooled(0.95, 5, 0.01, 1, 1)
n.pooled(0.95, 10, 0.1, 0.9, 1)
n.pooled(0.95, c(2, 5, 10, 20), 0.1, c(0.99, 0.98, 0.97, 0.95), 1)

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.