Limma interaction term
1
0
Entering edit mode
@3afc579a
Last seen 3 months ago
United States

Hi all. Currently I am working on differential gene expression analysis using limma R package. The metadata of my dataset includes both Treatment and Time variables. Example of the same is shown below :

I want to check the effect of interaction of both Treatment and Time over the expression of genes. After following the manual of Limma, I saw that interaction between the variables can be studied using the below method :

1) concatenate both Treatment and Time using "." as a separator, store it in a variable, say "Trt_time and build model using below formula :

design <- model.matrix(~0+Trt_time) The contrast to study the interaction between the variables was set as following :

cont.matrix <- makeContrasts( Interaction_Term=(Trt.6-Trt.0)-(UnTrt.6-UnTrt.0), levels=design) Is this the right way to study the combined effect of both variables on the gene expression?

2) Can the below formula yield similar results :

design <- model.matrix(~0+Time+Treatment+Time:Treatment) In what way are both the design formula different?

Thank You ! `

RNASeqData limma DifferentialExpression • 215 views
0
Entering edit mode
@gordon-smyth
Last seen 13 minutes ago
WEHI, Melbourne, Australia

This topic is explained in quite a bit of detail in Section 9.5 of the limma User's Guide.

The interaction term can be interpretted as the effect of the double variable effect (Treated and 6 hours) over the additive effects of the two variables.

The factorial model

design <- model.matrix(~Time+Treatment+Time:Treatment)

is completely equivalent to the model with the concatenated variable, but is harder to work with so I never recommend it. If you do fit the factorial model, please do not use ~0+ which is just out of place in that context.