Hi,
I am treating some RNASeq data whose experimental design includes three factors. I am interested, at first, in retrieving those genes showing the triple interaction, using voom + lmFit. I’ve read several posts on the matter, but none answered my question, so much so considering that one of my factors (i.e. time) presents multiple levels, and not just two. Is there any way to get the triple interaction out of this? IF so, should I always go through the makeContrast option and not writing the model as in “~factor1*factor2*factor3”?
I paste a code here below. Any help will be much appreciated. Thanks a lot.
David
design.factor <- paste(rep(c("Mock","Bact"),each=30),
rep(rep(c("in","out"),each=15),2),
rep(rep(c("0h","1h","2h","4h","6h"),each=3),2),sep=".")
library(edgeR)
dge <- DGEList(counts=counts, group=design.factor)
dge <- calcNormFactors(dge)
library(limma)
dge.voom <- voom(dge,plot=TRUE)
design=model.matrix(~0+design.factor)
fit <- lmFit (dge.voom,design)
Hi Aaron,
Thanks for such a helpful answer. Actually, I had started with a linear approach because I cuold not see how to implement a triple interaction on edgeR. HOwever, provided that I may do so with makeContrasts; I'd rather stick to the original edgeR pipeline. What do ou think? Thanks again.
David
How you parameterize your design matrix is independent of the choice between limma or edgeR. Any design matrix and contrasts that work for one analysis pipeline will work for the other.
Thanks a lot.
Best,
David
Dear Aaron Lun, do you have a source (textbook, manual) teaching the parametrization of such contrast matrices? I've already read Limma's reference manual, this reference and this one. But they do not included three-way interactions or more than two factor variables when building contrast matrices.
I'm asking because of all related posts here you're always very knowledgeable.
Thank you very much.