Adding gene set to GSVA
1
0
Entering edit mode
10 months ago
A ★ 3.9k

Hi

I am trying to add oncogenic signatures to GSVA but I don't know how to do that

> data(C6BroadSets) #http://software.broadinstitute.org/gsea/msigdb/collections.jsp#C2
Warning message:
In data(C6BroadSets) : data set ‘C6BroadSets’ not found
>

From this tutorial

How to use GSVA for the RNA-seq RPKM file

> topMatrixGSVA <- gsva(topMatrix, c6BroadSets, min.sz=10, max.sz=999999, abs.ranking=FALSE, verbose=TRUE)
Error in h(simpleError(msg, call)) : 
  error in evaluating the argument 'gset.idx.list' in selecting a method for function 'gsva': object 'c6BroadSets' not found
> 
>

I have also tried

anonicalC2BroadSets <- c6BroadSets[c(grep("^ERBB2_UP.V1_DN", names(c6BroadSets)),
+                                                                           grep("^ERBB2_UP.V1_UP", names(c6BroadSets)),
+                                                                          grep("^WNT_UP.V1_DN", names(c6BroadSets)))]
Error: object 'c6BroadSets' not found
>

How I can add c6 collection ti GSVA?

GSVA • 740 views
ADD COMMENT
0
Entering edit mode
10 months ago
h.mon 32k

The problem is you will have to create the C6: oncogenic signatures yourself, because they are not included in any package. The tutorial you linked to works because c2BroadSets is included in the package GSVAdata. The GSVAdata has this description on how c2BroadSets was created:

The data is contained in an GeneSetCollection object called c2BroadSets obtained by parsing the file c2.all.v3.0.entrez.gmt, downloaded from http://www.broadinstitute.org/gsea, using the getGmt() function from the GSEABase package.

ADD COMMENT
1
Entering edit mode

you will have to create the C6: oncogenic signatures yourself, because they are not included in any package

There is msigdbr: https://cran.r-project.org/web/packages/msigdbr/vignettes/msigdbr-intro.html

msigdbr::msigdbr(species = "Homo sapiens", category = "C6")
ADD REPLY
0
Entering edit mode

Thank you

How I prepare that for GSVA

canonicalC6BroadSets <- GeneSetCollection(msigdbr::msigdbr(species = "Homo sapiens", category = "C6"))
Error in validObject(.Object) : 
  invalid class “GeneSetCollection” object: 1: members must all be 'GeneSet' classes
invalid class “GeneSetCollection” object: 2: unable to find an inherited method for function ‘setName’ for signature ‘"character"’
>
ADD REPLY
1
Entering edit mode

The problem is you are trying to convert it to a GeneSetCollection object. You don't need to do that. GSVA can also take a basic list object (like in the fgsea example in the vignette I linked to).

m_df = msigdbr::msigdbr(species = "Homo sapiens", category = "C6")
m_list = split(x = m_df$gene_symbol, f = m_df$gs_name)
ADD REPLY
0
Entering edit mode

Great post here! I was looking for exactly the same answer!

To get gene sets in ENSEMBL ids, what can I do?

Thank you!

ADD REPLY
0
Entering edit mode

You meant I have to use getGmt() to convert c6.all.v7.1.entrez.gmt to c2BroadSets ?

> gsc <- getBroadSets("c6.all.v7.1.symbols.gmt")
Start tag expected, '<' not found
Error: 'getBroadSets' failed to create gene sets:
  1: Start tag expected, '<' not found
>
ADD REPLY
0
Entering edit mode

How come you ask about using getGmt(), and then you use getBroadSets()? Why don't you try getGmt()?

And no, don't call the new object c2BroadSets, it will overwrite the existing c2BroadSets from GSVAdata, if the package has been loaded.

ADD REPLY
0
Entering edit mode

Finally I used GSEA itself

gset <- gmtPathways("c6.all.v7.1.entrez.gmt")

I fed up regulated genes in one group and I got this

enter image description here

Does this mean KRAS pathway is being down regulated in this group?

ADD REPLY

Login before adding your answer.

Traffic: 2559 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6