Gsea Plot
4
3
Entering edit mode
7.8 years ago
lkmklsmn ▴ 950

Hi,
I thought this would be fairly straight forward but so far I have been surprisingly unsuccessful. I am looking for a R package which replicates the Gene Set Enrichment Analysis (GSEA) graphic. From my quick read-through of the GSEABase package it was not clear to me that I can reproduce the same graphic.
Any suggestions?

r gene enrichment • 11k views
3
Entering edit mode
6.1 years ago
Gordon Smyth ★ 3.9k

You can easily use the limma package to draw a gene set enrichment plot from a set of indices. For example

library(limma)
barcodeplot(statistic, index=indices)

where 'statistic' is the score by which you want to rank the genes and 'indices' is the vector of indices of genes in your set.

However this of course draws the style of plot that the limma authors like rather than being identical to the Broad Institute GSEA plot, the latter being specific to the Kolmorogov-Smirnov type enrichment statistic used by GSEA.

The Broad Institute code is copyrighted in such a way that Bioconductor package authors are not allowed to copy or adapt code from R-GSEA into a new package. And one probably couldn't reproduce the GSEA plot exactly without looking at the code. So it is not surprising that a reimplemented version has not appeared.

2
Entering edit mode
7.8 years ago

If you download the GSEA desktop version, it will automatically create these plots (for the top gene lists)

This how I always run GSEA. That same website has a download for R-GSEA, but I've never tried it. The desktop version requires files to be in a special format, but I would imagine the R package does as well.

2
Entering edit mode
5.5 years ago

I have written a post about a new tool that does just this: recreating the GSEA plots in a decent format using R. The post is here.

0
Entering edit mode

This works perfectly. No modification needed. Allows you to export in whatever file format you want from R.

1
Entering edit mode
7.8 years ago
lkmklsmn ▴ 950

Thats what I ended up doing. Downloading the JAVA desktop version. Fussing with data type conversions etc. Considering all the effort spent on documentation by the BROAD, it is an incredibly user-UN-friendly tool. Hard to believe that there really isnt an R package out there where I could just give it a ranked list of genes with the indices of the genes from my gene set of interest.

1
Entering edit mode

Feel free to write one yourself. ;-)