Rvalues and qvalues.

Share:

Description

rvalue gives adjusted p-values based on qvalues, whereas nqvalue is a wrapper of function qvalue from R package qvalue with simplified output.

Usage

1
2
3
rvalue(pvalue, robust = FALSE, ...)

nqvalue(pvalue, robust = FALSE,...)

Arguments

pvalue

Input numeric vector of p-values.

robust

Logical. If robust=TRUE, the estimate is more robust for small p-values (see package qvalue).

...

Further arguments passed to function qvalue from R package qvalue.

Value

A list with:

LFDR.hat

Vector of estimates of the LFDR.

p0.hat

Estimated p0.

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.hat for that feature is set to NA. Error messages are not suppressed.

Author(s)

Code: Marta Padilla
Documentation: Alaa Ali, Kyle Leckett, Marta Padilla.

References

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.

Storey JD. (2002) A direct approach to false discovery rates. Journal of the Royal Statistical Society, Series B, 64: 479-498.

See Also

p0est and qvalue package.

Examples

1
2
3
4
5
6
7
8
# a p-values vector with missing elements
pp <- runif(15) ;pp[c(13,2,5)]<-NA

z1 <-rvalue(pvalue = pp, robust = TRUE)
z2 <-rvalue(pvalue = pp, pi0.method="bootstrap")

z3<- nqvalue(pvalue = pp, robust = TRUE)
z4<- nqvalue(pvalue = pp, pi0.method = "bootstrap")