Question: Gsva Analysis In R: Unable To Identify Method For Function
0
gravatar for k.nirmalraman
6.6 years ago by
k.nirmalraman1000
Germany
k.nirmalraman1000 wrote:

Hi All,

I am trying to do gene set variance analysis using GSVA package for different samples. I have a list of signification genes as ExpressionSet and a GeneSet

  > eset<-new("ExpressionSet",exprs=as.matrix(scaledcounts))

  > eset
   ExpressionSet (storageMode: lockedEnvironment)
   assayData: 25658 features, 21 samples 
   element names: exprs 
    : none
   phenoData: none
   featureData: none
   experimentData: use 'experimentData(object)'
   Annotation: none

and my Gene list is

GeneIDs<-c("abc","cda","xcv",.....)

which I am conversiting to a GeneSet

`HpoGS<-GeneSet(GeneIDs,geneIdType=NullIdentifier(),setName="Hpo")

I am getting the following error message, which I am failing to understand with my limited knowledge in oo programming.

`gsva<-gsva(eset,HpoGS)
 Error in (function (classes, fdef, mtable)  : 
 unable to find an inherited method for function ‘gsva’ for signature ‘"ExpressionSet", "GeneSet", "missing"’

I am wondering does it have anything to do with the way, I am creating the expressionSet or GeneSet? Any help to address this would be highly appreciated. Thanks a lot in advance!

enrichment R • 6.0k views
ADD COMMENTlink modified 5.0 years ago by smacneil880 • written 6.6 years ago by k.nirmalraman1000

I don't know anything about gvsa, but a first step here would be to use showMethods('gsva'), which should show the combinations of of classes gvsa can take (referred to as a signature in the error message)

ADD REPLYlink written 6.6 years ago by David W4.7k

First step is ?gsva

ADD REPLYlink written 6.6 years ago by Michael Dondrup47k
1
gravatar for Michael Dondrup
6.6 years ago by
Bergen, Norway
Michael Dondrup47k wrote:

According to the documentation of GSVA:

gset.idx.list Gene sets provided either as a list object or as a GeneSetCollection object.

So, you have provided a GeneSet object, but either a list or GeneSetCollection object is required. The GeneSetCollection class is part of the package GSEA base and described in its documentation. Making a list of genes is probably even easier.

ADD COMMENTlink written 6.6 years ago by Michael Dondrup47k
0
gravatar for smacneil88
5.0 years ago by
smacneil880
United States
smacneil880 wrote:

I am not sure what gene sets you are using, but if you are using GeneSets from the Molecular Signatures Database just read them in as a list.

geneSets="c2.symbols.gmt"

geneSets=readList(geneSets)

As far as your expression data goes, just read it in as Matrix. GSVA can also take a matrix. 

microarrayData <- read.delim("SomeData.txt", check.names=FALSE, row.names=1)
microarrayData= as.matrix(microarrayData)

gsva_analysis <- gsva(microarrayData, ggeneSets, min.sz=1, max.sz=Inf, verbose=TRUE, rnaseq=FALSE)$es.obs

 

ADD COMMENTlink written 5.0 years ago by smacneil880
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1574 users visited in the last hour