Question: How barcode-plot enrichment is calculated?
gravatar for elim
14 months ago by
elim0 wrote:


I have been trying to find how the enrichment for the barcode plot is calculated. It seem to be different from the "traditional" GSEA with random-walk since the scores already starts high.

The value of enrichment seems to change according to the worm.span. For example, with default value I get a max enrichment of 1.3, while if it to 0.05 the peak goes to 2 and is not inside the "colored-area". Which I find strange since I calculated using camera and the set is enriched.

Another question is if there is a way to capture the enrichment score value or the value of the peak.


limma camera barcodeplot • 772 views
ADD COMMENTlink modified 14 months ago by Gordon Smyth39k • written 14 months ago by elim0
Answer: How barcode-plot enrichment is calculated?
gravatar for Gordon Smyth
14 months ago by
Gordon Smyth39k
Walter and Eliza Hall Institute of Medical Research, Melbourne, Australia
Gordon Smyth39k wrote:

The worm gives the obvious thing, which is the relative density of gene-set genes in a span about each position. If the height of the worm is 1.3, then the number of set genes around that point is 30% higher than if the coverage was uniform.

You can read complete details of the computation from the documentation. On the help("barcodeplot") page, there is a link near the bottom to help("tricubeMovingAverage") which is the function that does the detailed worm computations.

It is of course not the same as the Broad Institute's GSEA plot, because the GSEA plots correspond to GSEA's Kolmogorov-Smirnov test and don't make sense in any other context. We are not doing the Kolmogorov-Smirnov test, so it makes no sense to make the same plot. Instead we make a simpler and more intuitive plot (so it seems to me anyway) that makes sense in a more general context.

I am not sure why you are changing the span to 0.05. That is much too small a value to be of practical use.

There is no reason why the peak, if there is a peak, should be in the colored region of the bar. The colored region doesn't have anything to do with the camera test.

There isn't really any enrichment score value other than the peak relative density shown on the plot. The plot function doesn't return this value as a formal function value. If you want a formal score, it is better to use the camera test, and then the p-value itself is the enrichment score.

ADD COMMENTlink modified 14 months ago • written 14 months ago by Gordon Smyth39k

Thank you for your explanation Gordon, makes sense to me now.

ADD REPLYlink written 14 months ago by elim0
Please log in to add an answer.


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