[BioC] Error in function read.spikein of affycomp

cstrato cstrato at aon.at
Mon Dec 15 22:52:05 CET 2008


Dear Rafael

Meanwhile I looked at the source code of "affycomp" and realized that it 
contains defunct Biobase classes.

When changing the code for function "read.spikein" to:

read.spikein <- function(filename,cdfName=c("hgu95a","hgu133a"),
                         remove.xhyb=TRUE){
  cdfName <- match.arg(cdfName)
  s <- read.csv(filename,check.names=FALSE,row.names=1)
  samplenames <- colnames(s)
  ##remove the .cel if its there
  samplenames <- sub("\\.gz$","",samplenames,ignore.case=TRUE)
  samplenames <- sub("\\.Z$","",samplenames,ignore.case=TRUE)
  samplenames <- sub("\\.cel$","",samplenames,ignore.case=TRUE)
  colnames(s) <- samplenames
  ##read phenodata
  if(cdfName=="hgu95a"){
    data(spikein.phenodata)
    pd <- spikein.phenodata
  }
  if(cdfName=="hgu133a"){
    data(hgu133a.spikein.phenodata)
    pd <- hgu133a.spikein.phenodata 
  }
pd <- as(pd,"AnnotatedDataFrame") #<== new
  ##putit in order
  s <- s[,rownames(pData(pd))]
s <- log(s)  #<== new
  s <- new("ExpressionSet",exprs=as.matrix(s),phenoData=pd)
#delete  s <- exprset.log(s) ##take log
  if(remove.xhyb & cdfName=="hgu133a") s <- remove.hgu133a.xhyb(s)
  return(s)
}

then I can import the example using:

 > s <- read.spikein.test("s_rma.csv")

However, then I get the next error:

 > assess.rma <- assessSpikeIn(s, method.name="RMA")
Performing 6 assessments that will take a few minutes.....Error: 
'geneNames' is defunct.
Use 'featureNames' instead.
See help("Defunct") and help("Biobase-defunct").
 >

It would be great if you could update the "affycomp" package asap to 
work with BioC 2.3.

Thank you in advance.
Best regards
Christian


cstrato wrote:
> Dear all,
>
> I would like to use affycomp for my data, but even using the example 
> data "s_RMA.csv" I get the following error when trying to read the data:
>
> > s <- read.spikein("s_RMA.csv")
> Error in function (classes, fdef, mtable)  :
>  unable to find an inherited method for function "pData", for 
> signature "phenoData"
>
> > sessionInfo()
> R version 2.8.0 (2008-10-20)
> i386-apple-darwin8.11.1
>
> locale:
> C
>
> attached base packages:
> [1] tools     stats     graphics  grDevices utils     datasets  
> methods  [8] base    
> other attached packages:
> [1] affycomp_1.18.0 Biobase_2.2.1  >
>
> Do you know the reason for this error?
>
> Best regards
> Christian
> _._._._._._._._._._._._._._._._._._
> C.h.r.i.s.t.i.a.n   S.t.r.a.t.o.w.a
> V.i.e.n.n.a           A.u.s.t.r.i.a
> e.m.a.i.l:        cstrato at aon.at
> _._._._._._._._._._._._._._._._._._
>
> _______________________________________________
> 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
>
>



More information about the Bioconductor mailing list