mmpa: Mini Pooling algorithm with covariates

Description Usage Arguments Value Examples

View source: R/mmpa.R

Description

This function allows you to compute the average number of assays needed per pool using mini pooling algorithm with covariates.

Usage

1
2
mmpa(v, s, K = 5, vf_cut = 1000, lod = 0, method = "permutation",
  perm_num = 100)

Arguments

v

Vector of viral load.

s

Vector of risk score with the same length of viral load.

K

Pool size, default is 5.

vf_cut

Cutoff for individual viral failure, default is 1000.

lod

Vector of true VL of those undetectable, default is 0.

method

The method used for the average test number calculation, default is "permutation".

perm_num

The number of permutation to be used for the calculation, default is 100.

Value

The average number of assays needed per pool and per subject.

Examples

1
2
3
4
5
d = Simdata
V = d$VL # Viral Load
S = d$S # Risk Score
mmpa(V, S, K = 3, perm_num = 3)
foo; table(foo)

yizhenxu/mMPA documentation built on May 4, 2019, 5:29 p.m.