lfdr.bbe: Binomial-based LFDR estimator.

Description Usage Arguments Value Note Author(s) References See Also Examples

View source: R/000092PSIhat.v0.R

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

1
2
3
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.

Note

If computation fails for all features, p0.hat is set to NA and LFDR.hat is set to a vector of NA with lengh equal to the number of features. If it fails for a given feature, only the resulting LFDR for that feature is set to NA. Error messages are not suppressed.

Author(s)

Code: David R. Bickel and Marta Padilla (modifications),
Documentation: Alaa Ali, Kyle Leckett, Marta Padilla.

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

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
# 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)

PsiHat documentation built on May 30, 2017, 7:12 a.m.