I have a gene set containing a set of 1500 genes in which I did differential gene expression using limma voom pipeline. After this step I wanted to analyze a specific set of pathways the metabolism set from KEGG database.
hs_kegg_df <- msigdbr(species = "Homo sapiens") %>%
dplyr::filter(
gs_cat == "C2", # This is to filter only to the C2 curated gene sets
gs_subcat == "CP:KEGG" # This is because we only want KEGG pathways
)
Then since I only want to analyze metabolism I did this (keep only the pathways envolved in metabolism):
hs_kegg_df_with_gs_source <- subset(hs_kegg_df, grepl("^hsa00|^hsa01|^hsa02", gs_exact_source))
My problem is that, for example, for the pathway KEGG arginine and proline metabolism the set contains 54 genes in which my kit only covers 4, and these for 4 genes are Differentially expressed yet when doing: ( I decided to do ORA because with 1500 genes GSEA is not recommended).
em <- enricher(genes, minGSSize=1, maxGSSize = 20, universe = names(gene_list), TERM2GENE=hs_kegg_df,pAdjustMethod = "fdr")
This set does not appear with significant p value. I also tried passing to the enricher just that pathway in particular, the p value is 1. Because in hypergeometric test, the background genes are the same as the as DGE genes in all pathways giving this way 1-0=1.
How can I analyze just one pathway in particular given this specific conditions?