Learn R Programming

PsiHat (version 1.0)

lfdr.bbe: Binomial-based LFDR estimator.

Description

A binomial-based estimator of the local false discovery rate (BBE) with p0 estimation (use lfdr.bbe). When p0 = 1 the estimator is called BBE1 (use lfdr.bbe1).

Usage

lfdr.bbe(pvalue, p0 = NULL, robust = FALSE, monotonic = FALSE, ...) lfdr.bbe1(pvalue, robust = FALSE, monotonic = FALSE, ...)

Arguments

pvalue
Input numeric vector of p-values.
p0
Proportion of non-affected features, it is NULL or a value within [0,1]. For lfdr.bbe1 p0=1, while for lfdr.bbe it can be set or it can be estimated internally by p0est, setting p0=NULL (the default value).
robust
Logical. If robust=TRUE, the estimate is more robust for small p-values. If robust=TRUE, the estimate is more robust for small p-values (see package qvalue).
monotonic
Logical. If monotonic=TRUE, LFDR estimates are monotonically increasing with p-values.
...
Further arguments passed to function p0est.

Value

A list with:
LFDR.hat
Vector of estimates of the LFDR,
p0.hat
Estimated p0 (for BBE), 1 (for BBE1)
pvalue
Vector of p-values.
info
Method name and information about computation failure.

References

Bickel, D. R. (2013). Simple estimators of false discovery rates given as few as one or two p-values without strong parametric assumptions. Statistical Applications in Genetics and Molecular Biology, Statistical Applications in Genetics and Molecular Biology, 12(4), pp. 529-43.

Padilla, M., & Bickel, D. R. (2012). Estimators of the local false discovery rate designed for small numbers of tests. Statistical Applications in Genetics and Molecular Biology, 11(5), art. 4.

See Also

qvalue package and p0est and nqvalue.

Examples

Run this code
# a p-values vector with missing elements
pp <- runif(15) ;pp[c(13,2,5)]<-NA

#BBE1:
z1 <- lfdr.bbe1(pvalue = pp, robust = TRUE)
z2 <- lfdr.bbe1(pvalue = pp, robust = FALSE, monotonic = TRUE)

#estimating or setting p0:
z3 <- lfdr.bbe(pvalue = pp, p0 = NULL)
z4 <- lfdr.bbe(pvalue = pp, pi0.method = "bootstrap")
z5 <- lfdr.bbe(pvalue = pp, p0 = 0.8, robust = TRUE, monotonic = TRUE)



Run the code above in your browser using DataLab