Hello,
I am running a microarray analysis using a zebrafish platform pd.zebgene.1.1.st). After performing the moderated t-test in limma (lmFit/eBayes), I am using the resulting MArrayLM object to map the returned Entrez ID's to "dre" (KEGG) and "dr" (GO) databases.
I need help with:
1) Restricting only the probesets with: adjusted P.value < 0.01 and logFC > 1.5, < -1.5 from the fit object when passing the goana function. Can this be done using the topTable?
2) How to determine which genes are assigned to each enriched GO term?
For example I would like to describe which differentially expressed probesets are returned from (GO:0050877)
Term | Ont | N | Up | Down | P.Up | P.Down | |
GO:0050877 | neurological system process | BP | 258 | 65 | 47 | 1.57E-20 | 0.029498 |
GO:0008066 | glutamate receptor activity | MF | 22 | 0 | 18 | 1 | 1.44E-12 |
GO:0005096 | GTPase activator activity | MF | 114 | 2 | 41 | 0.997429 | 2.5E-09 |
GO:0016917 | GABA receptor activity | MF | 16 | 0 | 13 | 1 | 2.56E-09 |
Thanks for any help you can provide,
Matt
library(limma) design = model.matrix(~ 0 + f) colnames(design)=c("control","morphant","rescue") data.fit = lmFit(eset,design) contrast.matrix <- makeContrasts(morphant-control,rescue-control,morphant-rescue,levels=design) data.fit.con <- contrasts.fit(data.fit,contrast.matrix) data.fit.eb <- eBayes(data.fit.con) entzzvec<-as.vector(data.fit.eb$genes$ENTREZID) MOkegg<-kegga(data.fit.eb,coef=1,geneid=entzzvec,FDR=0.01,species.KEGG="dre",convert=TRUE) MOtop<-topKEGG(MOkegg, sort = NULL, number = 50, truncate.path = NULL)
The code you give doesn't use the goana() function. There is also no need for the as.vector() step.
sorry, I was not paying attention and posted the kegg script by accident.
I had to use the as.vector step to map gene symbols to Entrez ID's in org.Dr.eg.db:
Actually you don't ever need as.vector(). You used as.character() for the mapping, not as.vector(). With goana() you could use:
which is a bit shorter.
Thank you, Gordon. With your help, I figured out How to determine which genes are assigned to each enriched GO term. I will do some reading regarding the comments/links you posted and try to determine which method might be best for my dataset