View source: R/poolbinom.lrt.R
| poolbinom.lrt | R Documentation |
Calculate LRT based confidence interval for the Bernoulli
proportion of k\cdot n individuals, which are pooled into n pools
each of size k. Observed is the number of positive pools x.
poolbinom.lrt(x, k, n, conf.level=0.95, bayes=FALSE, conf.adj=FALSE)
x |
Number of positive pools (can be a vector). |
k |
Pool size (can be a vector). |
n |
Number of pools (can be a vector). |
conf.level |
The level of confidence to be used in the confidence interval |
bayes |
See |
conf.adj |
See |
Compute LRT based intervals for the binomial response
X \sim Bin(n, \theta), where \theta = 1 - (1-\pi)^k.
As a consequence,
\pi = g(\theta) = 1 - (1-\pi)^{1/k}
.
One then knows that the borders for \pi are just transformations
of the borders of theta using the above g(\theta) function.
For further details about the pooling setup see
poolbinom.logit.
A data.frame containing the observed proportions and the lower and
upper bounds of the confidence interval. The output is similar
to the binom.confint function of the binom package
M. Höhle
binom.lrt(x=0:34,n=34)
poolbinom.lrt(x=0:34,k=1,n=34)
poolbinom.lrt(x=0:34,k=10,n=34)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.