lfdr(p, pi0 = NULL, trunc = TRUE, monotone = TRUE, transf = c("probit",
"logit"), adj = 1.5, eps = 10^-8, ...)pi0est is called.adj=1.0.pi0est.p.pi0est.
This function works by forming an estimate of the marginal density of the
observed p-values, say $\hat{f}(p)$. Then the local FDR is estimated as
${\rm lFDR}(p) = \hat{\pi}_0/\hat{f}(p)$, with
adjustments for monotonicity and to guarantee that ${\rm lFDR}(p) \leq
1$. See the Storey (2011) reference below for a concise
mathematical definition of local FDR.Storey JD. (2003) The positive false discovery rate: A Bayesian
interpretation and the q-value. Annals of Statistics, 31: 2013-2035.
Storey JD. (2011) False discovery rates. In International Encyclopedia of Statistical Science.
qvalue, pi0est, hist.qvalue# import data
data(hedenfalk)
p <- hedenfalk$p
lfdrVals <- lfdr(p)
# plot local FDR values
qobj = qvalue(p)
hist(qobj)Run the code above in your browser using DataLab