[BioC] biobase phenodata

Sean Davis sdavis2 at mail.nih.gov
Mon Sep 8 20:52:00 CEST 2008


On Mon, Sep 8, 2008 at 2:37 PM, hemant ritturaj
<ritturajhemant at gmail.com> wrote:
> Dear all,
>
> I was trying to make expression set from the GSE data

This will get you an ExpressionSet:

gse6901.eset <- getGEO("GSE6901")[[1]]

Now, gse6901.eset is an ExpressionSet.  No need for all the code
below.  The [[1]] is needed because getGEO() on a GSEMatrix returns a
list of ExpressionSets.  In this particular case, there is only one
ExpressionSet, so we choose it.

Sean

> Following is the code
>
> gse6901 <- getGEO("GSE6901", GSEMatrix=F)
> probesets <- Table(GPLList(gse6901)[[1]])$ID
> data.matrix <- log2(do.call("cbind", lapply(GSMList(gse6901), function(x) {
> + tab <- Table(x)
> + mymatch <- match(probesets, tab$ID_REF)
> + return(as.numeric(tab$VALUE[mymatch]))
> + })))
> rownames(data.matrix) <- probesets
> colnames(data.matrix) <- names(GSMList(gse6901))
> pdata <- data.frame(samples = names(GSMList(gse6901)))
> rownames(pdata) <- names(GSMList(gse6901))
> pheno <- new("phenoData", pData = pdata, varLabels = as.list("samples"))
>
>
> Error: The phenoData class is defunct, use AnnotatedDataFrame (with
> ExpressionSet) instead
>
> I am not able to understand what function has exactly gor changed in Biobase
> module as I tried
>
> pheno <- new("AnnotatedDataFrame", pData = pdata, varLabels =
> as.list("samples"))
>
> then again got an error
>
> Error in .nextMethod(.Object, ...) :
>  invalid names for slots of class "AnnotatedDataFrame": pData, varLabels
>
> Kindly anyone please help me sorting out this error, I shall be very
> thankful for your kind help
>
> Regards
> --
> Hemant Ritturaj Kushwaha
>
>        [[alternative HTML version deleted]]
>
> _______________________________________________
> 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