Hi guys,
I'm trying to run DESeq2 on my HTSeq-count files
I've got 6 samples : 3 conditions with 2 replicates . I'd like to compare each condition between each other : 0h vs 6h , 0h vs 24h and 6h vs 24h
So my, my sampleTable looks like this :
> sampleTable
samples samples.1 condition
1 SRR2033948 SRR2033948 0h
2 SRR2033949 SRR2033949 0h
3 SRR2033950 SRR2033950 6h
4 SRR2033951 SRR2033951 6h
5 SRR2033952 SRR2033952 24h
6 SRR2033953 SRR2033953 24h
My dds looks like this :
> dds
class: DESeqDataSet
dim: 200542 6
metadata(1): version
assays(4): counts mu H cooks
rownames(200542): AT1G01010:exon:1 AT1G01010:exon:2 ...
ATMG09960:exon:2 ATMG09980:exon:1
rowData names(26): baseMean baseVar ... deviance maxCooks
colnames(6): SRR2033948 SRR2033949 ... SRR2033952 SRR2033953
colData names(2): condition sizeFactor
I've created my 3 contrast comparisons :
res.A.B <- results(dds, contrast=c("condition","0h","6h"))
res.B.C <- results(dds, contrast=c("condition","6h","24h"))
res.A.C <- results(dds, contrast=c("condition","0h","24h"))
It works, but when I run resultsNames(dds) , I get
> resultsNames(dds)
[1] "Intercept" "condition_24h_vs_0h" "condition_6h_vs_0h"
So, the contrast "condition_24h_vs_6h" doesn't appear and consequently, I can't shrink it.
> res_BC_LFC<-lfcShrink(dds,coef="condition_24h_vs_6h",type="apeglm")
Error in lfcShrink(dds, coef = "condition_24h_vs_6h", type = "apeglm") :
coef %in% resultsNames(dds) is not TRUE
So , I don't understand why I could run res.B.C <- results(dds, contrast=c("condition","6h","24h"))
Any suggestion why the contrast "condition_24h_vs_6h" doesn't appear?
Best,
Vincent