Description Usage Arguments Value Examples
View source: R/freedom_functions_1.R
Calculates population-level sensitivity where unit sensitivity varies and using the appropriate method, depending on whether or not N provided (hypergeometric if N provided, binomial otherwise), assuming perfect test specificity and representative sampling
1 | sep.var.se(N = NA, se, pstar)
|
N |
population size (number of units or clusters), N must be >= length(se)) or NA if unknown |
se |
vector of unit sensitivity values (proportion) for each unit sampled |
pstar |
specified design prevalence (scalar) |
a scalar of population-level sensitivity
1 2 3 4 5 6 7 | # examples of sep.var.se - checked
sens<- c(rep(0.9, 50), rep(0.95, 100))
sep.var.se(NA, sens, 0.01)
sep.var.se(se=sens, pstar=0.01)
sep.var.se(N=500, sens, 0.01)
sep.var.se(NA, runif(150, 0.95, 0.99), 0.02)
sep.var.se(500, runif(150, 0.95, 0.99), 0.02)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.