qvalue: Estimate the q-values for a given set of p-values

View source: R/qvalue.R

qvalueR Documentation

Estimate the q-values for a given set of p-values

Description

Estimate the q-values for a given set of p-values. The q-value of a test measures the proportion of false positives incurred (called the false discovery rate) when that particular test is called significant.

Usage

qvalue(p, fdr.level = NULL, pfdr = FALSE, lfdr.out = TRUE, pi0 = NULL,
  ...)

Arguments

p

A vector of p-values (only necessary input).

fdr.level

A level at which to control the FDR. Must be in (0,1]. Optional; if this is selected, a vector of TRUE and FALSE is returned that specifies whether each q-value is less than fdr.level or not.

pfdr

An indicator of whether it is desired to make the estimate more robust for small p-values and a direct finite sample estimate of pFDR – optional.

lfdr.out

If TRUE then local false discovery rates are returned. Default is TRUE.

pi0

It is recommended to not input an estimate of pi0. Experienced users can use their own methodology to estimate the proportion of true nulls or set it equal to 1 for the BH procedure.

...

Additional arguments passed to pi0est and lfdr.

Details

The function pi0est is called internally and calculates the estimate of \pi_0, the proportion of true null hypotheses. The function lfdr is also called internally and calculates the estimated local FDR values. Arguments for these functions can be included via ... and will be utilized in the internal calls made in qvalue. See http://genomine.org/papers/Storey_FDR_2011.pdf for a brief introduction to FDRs and q-values.

Value

A list of object type "qvalue" containing:

call

Function call.

pi0

An estimate of the proportion of null p-values.

qvalues

A vector of the estimated q-values (the main quantity of interest).

pvalues

A vector of the original p-values.

lfdr

A vector of the estimated local FDR values.

significant

If fdr.level is specified, and indicator of whether the q-value fell below fdr.level (taking all such q-values to be significant controls FDR at level fdr.level).

pi0.lambda

An estimate of the proportion of null p-values at each \lambda value (see vignette).

lambda

A vector of the \lambda values utilized to obtain pi0.lambda.

Author(s)

John D. Storey

References

Storey JD. (2002) A direct approach to false discovery rates. Journal of the Royal Statistical Society, Series B, 64: 479-498.
http://onlinelibrary.wiley.com/doi/10.1111/1467-9868.00346/abstract Storey JD and Tibshirani R. (2003) Statistical significance for genome-wide experiments. Proceedings of the National Academy of Sciences, 100: 9440-9445.
http://www.pnas.org/content/100/16/9440.full

Storey JD. (2003) The positive false discovery rate: A Bayesian interpretation and the q-value. Annals of Statistics, 31: 2013-2035.
http://projecteuclid.org/DPubS/Repository/1.0/Disseminate?view=body&id=pdf_1&handle=euclid.aos/1074290335

Storey JD, Taylor JE, and Siegmund D. (2004) Strong control, conservative point estimation, and simultaneous conservative consistency of false discovery rates: A unified approach. Journal of the Royal Statistical Society, Series B, 66: 187-205.
http://onlinelibrary.wiley.com/doi/10.1111/j.1467-9868.2004.00439.x/abstract

Storey JD. (2011) False discovery rates. In International Encyclopedia of Statistical Science.
http://genomine.org/papers/Storey_FDR_2011.pdf
http://www.springer.com/statistics/book/978-3-642-04897-5

See Also

pi0est, lfdr, summary.qvalue, plot.qvalue, hist.qvalue, write.qvalue

Examples

# import data
data(hedenfalk)
p <- hedenfalk$p

# get q-value object
qobj <- qvalue(p)
plot(qobj)
hist(qobj)

# options available
qobj <- qvalue(p, lambda=0.5, pfdr=TRUE)
qobj <- qvalue(p, fdr.level=0.05, pi0.method="bootstrap", adj=1.2)


StoreyLab/qvalue documentation built on Sept. 4, 2023, 11:24 p.m.