sspa_gsea
.sspa_gsea(
mat, metadata, pathway_df, ranking_metric = 'signal_to_noise', min_entity = 2
)
Run GSEA using gseapy package by zqfang (https://github.com/zqfang/GSEApy)
Args
- mat (pd.DataFrame) : dataframe containing input metabolomics data
- metadata (pd.Series) : series containing phenotype metadata e.g 'COVID', 'NON-COVID'
- pathway_df (pd.DataFrame) : GMT-like pathway dataframe containing compound identifiers
- ranking_metric (str) : Ranking metric for molecules in GSEA. Default is signal-to-noise ratio. Other options are 't_test' and see GSEApy package https://github.com/zqfang/GSEApy/blob/2b5419e14615b6fd19a575ff065256dc7099bbec/gseapy/gsea.py#L135 for more options.
- min_entity (int, optional) : minimum number of molecules mapping to pathways for GSEA to be performed. Defaults to 2.