Rank statistic for enrichment analysis

Hello,

I used HUMAnN4 gene family abundance outputs and humann_regroup_table to map UniRef gene families to KEGG Orthologs. I then used the resulting KO abundance table as input to MaAsLin3 to test KO-level associations.

I would now like to use the MaAsLin3 results to rank KOs for KEGG pathway enrichment (GSEA). I could not find much guidance on using MaAsLin3 outputs for this purpose. Previously, I have used (sign)(lfc) * -log(p). In this case would the equivalent be:

((sign)coef -(null hypothesis)) * -log(p)?

I am using default median_comparison_abundance = TRUE; but subtract_median = FALSE. My understanding is that coef contains the original fitted coefficient, while pval tests whether that coefficient differs from null_hypothesis. Therefore, the direction of the ranking should be based on coef - null_hypothesis, rather than coef alone. Is that correct and comparable to my desired ranking or do you suggest something else?

As a complementary analysis, I also plan to map the KOs to KEGG modules and pathways, calculate pathway-level abundance profiles, and run MaAsLin3 directly on those profiles but would like to compare ranked enrichment to determine whether the KOs within each pathway show coordinated positive or negative associations.

Thank you for your help!

Hi,

Yes - what you’ve described would be the right way to do it. You might also consider just running without the median comparison so that your results are for relative abundance rather than inferred absolute abundance. In that case, you’d just use the standard formula. If the null hypotheses are usually close to 0, it shouldn’t make much of a difference, but if they’re farther away it might change what you conclude somewhat.

Will

1 Like