Question: DESeq2 : foldchange calculation with multi-factor design
0
gravatar for Nicolas Rosewick
5.1 years ago by
Belgium, Brussels
Nicolas Rosewick8.4k wrote:

Hi,

I've a question concerning DESeq2. I've a multi-factor design as follow :

samples      condition      type
Sample_A1    untreated      X
Sample_A2    untreated      X
Sample_A3    untreated      Y
Sample_A4    untreated      Y
Sample_B1    treated        X
Sample_B2    treated        X
Sample_B3    treated        Y
Sample_B4    treated        Y

so I do

dds <- DESeqDataSetFromHTSeqCount(sampleTable=samples,directory="./",design= ~ type+condition)
dds <- DESeq(dds)
res <- results(dds)

In the results, I wonder how the log2foldchange is computed ? How it takes into account this two-factor design ?

 

Thanks

 

deseq2 multifactor • 3.9k views
ADD COMMENTlink modified 5.1 years ago by Michael Love1.9k • written 5.1 years ago by Nicolas Rosewick8.4k
2
gravatar for Michael Love
5.1 years ago by
Michael Love1.9k
United States
Michael Love1.9k wrote:

The two factor design is taken into account as with normal linear regression: we have a term which represents the changes due to type, and a term which represents the change due to condition. Then when you call results(), it is by default testing the condition treated vs untreated effect. But you could also test the type Y vs X effect (more on this in the vignette).

ADD COMMENTlink written 5.1 years ago by Michael Love1.9k

So in my code the foldchange in the results will only take the factor "condition" into account ? 

ADD REPLYlink written 5.1 years ago by Nicolas Rosewick8.4k

It's "log2 fold change of the condition while controlling for type".

ADD REPLYlink written 5.1 years ago by Devon Ryan92k

No. It is testing the condition term, but the design includes type, so the type effect is "taken into account" or "controlled for" in the model. You might want to check a reference on linear models for further reference on how this work.

ADD REPLYlink written 5.1 years ago by Michael Love1.9k
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1221 users visited in the last hour