deafferent results when using ranked list metric offset

18 views
Skip to first unread message

ilian atanassov

unread,
Sep 28, 2023, 1:49:21 PM9/28/23
to webgestalt
Hello,

I ran a small test:
Ran the "GSEA Sample Run" analysis and then took the input Gene, logFC values and added 2 to all the logFC values. Then performed the GSEA analysis again.

To my surprize the results were quite different in terms of categories that passed the significance, enrichment scores and NES scores, including the range of the NES scores, attached.

Why is that the case? Shouldn't the results be as identical as possible allowing for differences due to the permutation step? 

Is it the case that the absolute values of the ranked metric matter or is it that only the rank is important?


Best wishes,

Ilian

Webgestalt.pdf

ilian atanassov

unread,
Nov 9, 2023, 4:11:39 AM11/9/23
to webgestalt
Hi. Please check the original publication with the formula in the appendix. https://www.pnas.org/doi/10.1073/pnas.0506580102#appendix
And see how the absolute values of the "expression" raffect the ES.

On Sat, Sep 30, 2023 at 9:44 AM ilian atanassov <atanass...@googlemail.com> wrote:
Hi Yuxing,
I wasn't expecting that the sign would make such a difference. Is this something that is specific to how webgestalt performs GSEA or is it intrinsic to the GSEA algorithm?

Can you please point me to the correct article so that I can read up on it and understand this better?

Best wishes,

Ilian

On Sat, Sep 30, 2023 at 12:26 AM Yuxing Liao <yuxin...@gmail.com> wrote:
Hi Ilian,

Simply adding 2 changes some of the signs that will affect a lot. If you scale separately for positives and negatives, I think the ES will change a little.

Yuxing

--
You received this message because you are subscribed to the Google Groups "webgestalt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to webgestalt+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/webgestalt/8ff43dd8-c711-4ffb-a561-d890c608399fn%40googlegroups.com.

John Elizarraras

unread,
Nov 9, 2023, 12:29:09 PM11/9/23
to webgestalt
Hello Ilian,

I did a quick experiment by changing the rank offset of a list of scores  . The original ES was -0.26, but you can see in the plot below that adding or subtracting from all of the values had pretty different results. Most GSEA lists vary from a negative score to positive scores, where the median value probably is close to 0. In the normal list, when these median values are encountered, they will add very little to the running sum since their absolute value is small. The values on either end of the rank list will have larger absolute values, so they will have a larger effect on the score. When you shift the score up by add a positive constant value, the negative scores of the ranked list will have less of an effect on the running sum, since the absolute value of the negative ranks is now decreased. If you add too large a value, this would make the ES to change sign, which is what I observed in my quick test. This is a possible explanation for why you observed different results. I would guess the extent of this effect would vary on the rank distribution of your list and the value of the offset. Let me know if this is helpful. There may be more effects, such as the random permutations that will change your results, but I believe this is the underlying cause for the difference in results.

Best,
John
output2.png
Reply all
Reply to author
Forward
0 new messages