Description Usage Arguments Details Value Note Author(s) References See Also Examples
Calculate the expected number of tests and accuracy measures for each individual using informative two-stage hierarchical (Dorfman) testing, given a vector of individual probabilities and a testing configuration.
1 | inf.dorf.measures(prob, se, sp, N, pool.sizes)
|
prob |
vector of probabilities corresponding to each individual's risk of disease. |
se |
the sensitivity of the diagnostic test. |
sp |
the specificity of the diagnostic test. |
N |
block size/initial group size that is not tested. This is the total number of individuals being tested. The details of block.sz are given under 'Details'. |
pool.sizes |
a vector of pool sizes for the first stage of testing. |
This function utilizes the equations given by McMahan et al. (2012) for informative two-stage hierarchical (Dorfman) testing. It also repurposes functions written by Christopher S. McMahan (see http://chrisbilder.com/grouptesting) for the implementation of informative Dorfman testing and directly uses functions written for the calculation of the associated operating characteristics. This function calculates the operating characteristics for informative two-stage hierarchical (Dorfman) testing. Operating characteristics calculated are expected number of tests, and pooling sensitivity, pooling specificity, pooling positive predictive value, and pooling negative predictive value for each individual.
The specified N represents the block size used in the pool-specific optimal Dorfman (PSOD) method. This is the total number of individuals being tested by the algorithm. This block is not initially tested. Instead, multiple initial pool sizes within this block are found and tested in the first stage of testing. The second stage of testing consists of individual retesting. For more information on block size specification, see McMahan et al. (2012).
A list containing:
e |
the expected number of tests needed to decode all N individuals. |
v |
the variance of the total number of tests needed to decode all N individuals. |
summary |
a matrix containing the pool, probability of disease, pooling sensitivity, pooling specificity, pooling positive predictive value, and pooling negative predictive value for each individual. The pool column identifies which pool each individual is contained in for the first stage of testing. |
This function returns the pooling positive and negative predictive values for all individuals even though these measures are diagnostic specific; i.e., PPPV (PNPV) should only be considered for those individuals who have tested positive (negative).
The majority of this function was originally written by Christopher S. McMahan for McMahan et al. (2012). The function was obtained from http://chrisbilder.com/grouptesting. Minor modifications were made to the function for inclusion in the binGroup package.
McMahan2012abinGroup
Array.Measures
for calculating operating characteristics
under array testing without master pooling,
MasterPool.Array.Measures
for non-informative array
testing with master pooling, and inf.dorf.measures
for informative two-stage hierarchical testing. See
p.vec.func
for generating a vector of
individual risk probabilities for informative group testing.
This function repurposed code from opt.info.dorf
so that
PSOD testing could be implemented using all possible testing configurations
instead of a greedy algorithm. This function also used
characteristics.pool
and accuracy.dorf
to calculate operating characteristics for the optimal set of
pool sizes.
http://chrisbilder.com/grouptesting
Other Operating characteristic functions: Array.Measures
,
MasterPool.Array.Measures
,
hierarchical.desc2
Other Informative Dorfman functions: accuracy.dorf
,
characteristics.pool
,
opt.info.dorf
, opt.pool.size
,
pool.specific.dorf
,
thresh.val.dorf
1 2 3 4 5 6 7 8 9 10 11 12 13 | # Calculate the operating characteristics for
# informative two-stage hierarchical (Dorfman) testing
# with an overall disease prevalence of E(p(i)) = 0.01,
# where a block size of 50 is split into initial pools
# of 18, 13, 11, and 8 individuals.
# This example takes less than 1 second to run.
# Estimated running time was calculated using a
# computer with 16 GB of RAM and one core of an
# Intel i7-6500U processor.
set.seed(8791)
inf.dorf.measures(prob=beta.dist(p=0.01, alpha=2,
grp.sz=50, simul=TRUE), se=0.95, sp=0.95, N=50,
pool.sizes=c(18, 13, 11, 8))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.