Open grabearummc opened 3 years ago
Let's say I've already done the differential gene expression analysis. How can I continue with EnrichmentBrowser::import/sbea/nbea
?
Question 1: Most GSA methods only support two groups comparisons. That means, you'll need to break down multi-group comparisons into the atomic unit of several 2-group comparisons.
Question 2: let's say you would like to do a GO enrichment analysis with your results from limma (assuming you have human data):
se <- import(el, res)
go.gs <- getGenesets(org = "hsa", db = "go", onto = "BP")
sbea.res <- sbea("ora", se, go.gs, perm = 0)
gsRanking(sbea.res, signif.only = FALSE)
I think import
would then need to allow to specify which two groups you would like to compare / for which DE results should be imported. Good point.
I think
import
would then need to allow to specify which two groups you would like to compare / for which DE results should be imported. Good point.
Nice! I was thinking this through earlier, and that crossed my mind, but I wasn't 100% sure if that was the right thing to do. So should I filter out samples based on my intended comparison? So (using my example) should I remove group1
and group6
and then combine everything else?
Exactly. This is how you could produce an index vector that allows you to subset to the relevant samples for comparison (would make samples in groups 2 and 3 your reference group, ie group 0; change accordingly if you want samples in groups 4 and 5 to be the reference).
group <- c(1,1,1,2,2,3,3,3,4,4,4,5,5,5,6,6,6)
group[group %in% 2:3] <- 0
group[group %in% 4:5] <- 1
rel.samples <- group %in% 0:1
Good deal. Much appreciated @lgeistlinger!
What if I have a multi-factor experiment with more than 2 conditions? How can I use EnrichmentBrowser?