[BioC] Limma package: problem with p-value and t

James W. MacDonald jmacdon at med.umich.edu
Thu Sep 17 22:50:38 CEST 2009



Julie Zhu wrote:
> Dear Gordon,
> 
> I noticed that there is inconsistency between the t and p.value on the
> topTable output using Limma package to analyze a dye swap two channel array
> experiment. 
>         logFC  AveExpr        t      P.Value  adj.P.Val        B
> 1401 3.216254 11.74137 22.49546 1.041470e-05 0.07874703 3.435097
> 1537 3.344735 11.88007 18.07448 2.702061e-05 0.07874703 2.951114
> 
> The two-tailed p-value for t=22.49546 with df=1 would be 0.028
> 2*pt(-abs(22.49546),df=1), but the P.Value in the above output is 1.04e-05.
> Did I miss something? Could you please explain the inconsistency? Thanks!

The degrees of freedom will be somewhere around 3, but a bit larger 
because of the ebayes fit. You can get the actual value from your 
MArrayLM object, so what you really want is

2*pt(-abs(22.49546), fit$df.prior + fit$df.residual[1])

assuming you did something like

fit <- lmFit(<stuff>)
fit <- eBayes(fit)

Best,

Jim


> 
> Here is the design matrix and relevant code snippets.
> 
>    Dye mutant
>    1     -1
>    1     -1
>    1      1
>    1      1
> 
> design = cbind(Dye=1, mutant = c(-1,-1,1,1))
> fit = lmFit(MA, design)
> ### MA is a MAlist object
> fit3 = eBayes(fit)
> topTable(fit3, number=2, coef="mutant", adjust="fdr")
> 
> Here is my R session information.
> 
> R version 2.9.0 (2009-04-17)
> i386-apple-darwin8.11.1
> 
> locale:
> en_US.UTF-8/en_US.UTF-8/C/C/en_US.UTF-8/en_US.UTF-8
> 
> attached base packages:
> [1] stats     graphics  grDevices utils     datasets  methods   base
> 
> other attached packages:
> [1] limma_2.18.0
> 
> Thank you very much for your help!
> 
> Best regards,
> 
> Julie
> 
> _______________________________________________
> Bioconductor mailing list
> Bioconductor at stat.math.ethz.ch
> https://stat.ethz.ch/mailman/listinfo/bioconductor
> Search the archives: http://news.gmane.org/gmane.science.biology.informatics.conductor

-- 
James W. MacDonald, M.S.
Biostatistician
Douglas Lab
University of Michigan
Department of Human Genetics
5912 Buhl
1241 E. Catherine St.
Ann Arbor MI 48109-5618
734-615-7826



More information about the Bioconductor mailing list