DESeq2 interaction term
2
0
Entering edit mode
zkwu2011 • 0
@zkwu2011-11723
Last seen 4.7 years ago

 

Dear Mike:

I am using DESeq2 to analyse RNA-seq data and very appreciated its comprehensive functionality. In my data, the counts are affected by genotype and cell type. I think there is interaction between genotype and cell type. Therefore, interaction term should be considered. In the help pages of function "results", there are two options for doing this. One is adding the interaction term explicitly in the formula, the other is combing two factors into one factor named group. I run the examples provided in the help page and found that two options output different results. For example, log2 fold change are different. So, what's reason or rationale underlying this situation?

Sincerely

Zikai Wu

deseq2 • 964 views
ADD COMMENT
0
Entering edit mode

I got it. Thanks Bernd so much!

ADD REPLY
0
Entering edit mode

Added question: which option do you recommend? interaction term in the design formula or take your two factors and combine them into a group vector ? 

ADD REPLY
1
Entering edit mode

This depends on what you want:

if you want  differences between groups, a grouping vector is more straightforward, if you interested in interaction effects, a model with interaction terms is easier to interpret.

ADD REPLY
0
Entering edit mode

Does that means the absolute value of log fold change of gene computed by design with interaction term is usually larger than the absolute value of LFC computed by design with grouping variable?

ADD REPLY
1
Entering edit mode

No, this is not usually the case. The-fold-change shrinkage will primarily shrink fold changes for lowly expressed genes, as their fold changes are more variable than the fold changes of highly expressed genes. Following the NB model, the log fold changes have a variance that is very roughly proportional to

var(logFC) ~ 1/(raw gene expression counts) + dispersion

So a some proportion but not all (!) lowly expressed genes will have large fold changes by chance. Those are then shrunken.

So in a nutshell, the difference will mainly be visible in a certain proportion of the lowly expressed genes.

ADD REPLY
1
Entering edit mode
Bernd Klaus ▴ 590
@bernd-klaus-6281
Last seen 2.7 years ago
Germany

Dear Zikai,

If you run DESeq2 with an interaction term in the design formula, the beta-shrinkage is turned off, i.e. the fold changes are not shrunken. This is also mentioned in the examples section of the results:

# design with interactions terms by default have betaPrior=FALSE 

However, if you take your two factors and combine them into a group vector, the beta-shrinkage is performed, leading to  different fold change estimates. See also section 3.3. of the vignette for a thorough discussion of this.

 

Bernd

 

ADD COMMENT
0
Entering edit mode
zkwu2011 • 0
@zkwu2011-11723
Last seen 4.7 years ago

Thanks, Bernd. 

ADD COMMENT

Login before adding your answer.

Traffic: 338 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6