fgsea icon indicating copy to clipboard operation
fgsea copied to clipboard

plotEnrichment ranks labels

Open igordot opened this issue 6 years ago • 2 comments

Is it possible to add an option to add ranks labels to plotEnrichment()? Currently, it is not possible to determine the ranks order from the plot without some additional information. For example, if you are comparing KO to WT, it would be helpful add "KO" and "WT" to opposite ends of the X (ranks) axis.

Here is an example from limma::barcodeplot() to illustrate what I am trying convey: image

If that is outside the scope of this package, do you have any suggestions on how to best add something like that with least interference with other elements?

igordot avatar Dec 07 '19 21:12 igordot

Hi, it's a good question. I wasn't able to quickly find an easy way to do this. You can try to modify the plot yourself, as plotEnrichment function returns ggplot object.

assaron avatar Dec 09 '19 10:12 assaron

Additionally, you can use fgsea::plotEnrichment function source code as a template, and make your own function.

assaron avatar Dec 12 '19 09:12 assaron