[BioC] egdeR troubles under new R 3.02
James W. MacDonald
jmacdon at uw.edu
Wed Oct 9 16:55:18 CEST 2013
Hi Alex,
On Tuesday, October 08, 2013 10:42:33 PM, alogmail2 at aol.com wrote:
> Dear All,
>
>
> It seems edgeR has a bug under new R 3.0.2.
>
>
> Here is the example from LIMMA's guide for R-seq (p.111- etc):
>
>
>
> library(tweeDEseqCountData)
>> data(pickrell1)
>> Counts <- exprs(pickrell1.eset)
>> class(Counts)
> [1] "matrix"
>> dim(Counts)
> [1] 38415 69
>> Counts[1:5,1:5]
> NA18486 NA18498 NA18499 NA18501 NA18502
> ENSG00000127720 6 32 14 35 14
> ENSG00000242018 20 21 24 22 16
> ENSG00000224440 0 0 0 0 0
> ENSG00000214453 0 0 0 0 0
> ENSG00000237787 0 0 1 0 0
>> barplot(colSums(Counts)*1e-6, names=1:69, ylab="Library size (millions)")
>> Gender <- pickrell1.eset$gender
>
>
>
> etc.
>
>
> It finally results in:
>
>
>
> fit$df.prior
> [1] 4.6
>> summary(decideTests(fit))
> (Intercept) Gendermale
> -1 292 43
> 0 913 17251
> 1 16105 16
>> chrom <- fit$genes$Chr
>> plotMA(fit,array=2,status=chrom,values=c("X","Y"),col=c("red","blue"),main="Male vs Female",legend="bottomright")
> Error in (function (classes, fdef, mtable) :
> unable to find an inherited method for function ‘plotMA’ for signature ‘"MArrayLM"’
This is the sort of error you get when you have function masking. You
loaded the limma package, which has a plotMA function, then you loaded
(in an unknown order) the DESeq package, which also has a plotMA
function, then you loaded DESeq2 which _also_ has a plotMA function.
So when you say plotMA(<MArrayLM object>), R looks down the search path
and sees the plotMA function in either DESeq or DESeq2 (whichever was
loaded last), looks at the methods available, and says 'this function
doesn't work on that sort of object'.
The work-around is to use limma::plotMA(), which tells R to look for
the function in the correct package namespace.
Best,
Jim
>> abline(h=0,col="darkgrey")
> Error in int_abline(a = a, b = b, h = h, v = v, untf = untf, ...) :
> plot.new has not been called yet
>>
>
>
> Thanks
>
>
> Alex
>
>
> UC Berkeley, Molecular Toxicology
> Berkeley CA 94720
>
>
>
>
>> sessionInfo()
> R version 3.0.2 (2013-09-25)
> Platform: i386-w64-mingw32/i386 (32-bit)
>
>
> locale:
> [1] LC_COLLATE=English_United States.1252 LC_CTYPE=English_United States.1252 LC_MONETARY=English_United States.1252
> [4] LC_NUMERIC=C LC_TIME=English_United States.1252
>
>
> attached base packages:
> [1] parallel stats graphics grDevices utils datasets methods base
>
>
> other attached packages:
> [1] tweeDEseqCountData_1.0.9 DESeq2_1.1.45 RcppArmadillo_0.3.920.1 Rcpp_0.10.5 GenomicRanges_1.13.51 XVector_0.1.4
> [7] IRanges_1.19.38 DESeq_1.13.3 lattice_0.20-23 locfit_1.5-9.1 Biobase_2.21.7 BiocGenerics_0.7.5
> [13] edgeR_3.3.8 limma_3.17.26 BiocInstaller_1.11.4
>
>
> loaded via a namespace (and not attached):
> [1] annotate_1.39.0 AnnotationDbi_1.23.27 DBI_0.2-7 genefilter_1.43.0 geneplotter_1.39.05 grid_3.0.2
> [7] RColorBrewer_1.0-5 RSQLite_0.11.4 splines_3.0.2 stats4_3.0.2 survival_2.37-4 tools_3.0.2
> [13] XML_3.98-1.1 xtable_1.7-1
>
>
>
>
> [[alternative HTML version deleted]]
>
>
>
> _______________________________________________
> Bioconductor mailing list
> Bioconductor at r-project.org
> 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
University of Washington
Environmental and Occupational Health Sciences
4225 Roosevelt Way NE, # 100
Seattle WA 98105-6099
More information about the Bioconductor
mailing list