Comparison of Comparisons with DESeq2
1
0
Entering edit mode
dbretta25 • 0
@dbretta25-20534
Last seen 5.0 years ago

I have an experimental design with 4 groups, 6 replicates per group (1 control group "A", and 3 treatment groups "B", "C", and "D").

My design is ~ condition

My code is as follows:

dds <- DESeqDataSetFromMatrix(countData=my.counts, colData=coldata, design= ~ condition)
dds <- estimateSizeFactors(dds)
dds <- DESeq(dds)
resultsNames(dds)
[1] "Intercept" "gr_B_vs_A" "gr_C_vs_A" "gr_D_vs_A"

I am not sure how to define some of my comparisons of interest, primarily the comparison of comparisons:

(D - C) - (B - A)

Is it possible to define this contrast from the resultsNames above?

As an aside, I attempted to use the resultsNames to perform one comparison (D - C) in two ways: Once by specifying the "contrast" parameter of the results function like so:

res <- results(dds, contrast=c("condition", "D", "C"))

And again by utilizing the resultsNames like so:

res <- results(dds, contrast=list(c("gr_D_vs_A","gr_C_vs_A"))

I was thinking that they should be equivalent due to (D - A) - (C - A) = D - C, but I obtain different numbers of significant DE Genes from these two methods so it seems like my thinking is incorrect.

I am using DESeq2 version 1.22.2

Thanks for your help,

Brett

deseq2 comparison of comparisons compare two contrasts complex contrast • 1.4k views
ADD COMMENT
0
Entering edit mode
@mikelove
Last seen 10 hours ago
United States

There’s a whole section of the DESeq2 vignette on “interactions”, take a look there first.

ADD COMMENT
0
Entering edit mode

Thanks Michael,

I have read the interaction section of the vignette but I am having trouble taking that information/example and applying it to my design.

Do you have input on whether the two results examples I provided are two ways of performing the same contrast (D - C)? And if they should then have identical results in terms of DE Genes passing an adjusted pvalue cutoff?

ADD REPLY
0
Entering edit mode

You should make two new factors, say X and Y,

Such that:

X=0 and Y=0 => condition A

...

X=1 and Y=1 => condition D

Then test the X:Y interaction term.

ADD REPLY

Login before adding your answer.

Traffic: 875 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