Hi
I have 5 groups and 3 levels of batches. This is my code:
rna.o=DESeqDataSetFromMatrix(data,colD,design = ~projects+Subtypes)
rna.d.pair=DESeq(rna.o,parallel = T)
this is my resultsNames:
resultsNames(rna.d.pair)
[1] "Intercept" "projectsPACA.CAvsPACA.AU" "projectsPAEN.AUvsPACA.AU"
[4] "Subtypes2vs1" "Subtypes3vs1" "Subtypes4vs1"
[7] "Subtypes5vs1"
For the next step, how should I use contrasts for one vs multiple groups for example 2 VS 1,3,4,5?
So I just need to switch conditions in this list to get my desired comparison? should I change reference level for comparisons other than condition 1?
If you use the code I suggested, it doesn't matter what the reference level is, all levels will be present in the resultsNames(dds).
thanks Michael. It helped a lot...
Hi, I came across this because I am trying to do something similar, but I want to use
lfcShrink
, because I am working with single cell (I used zinbwave together with DESeq2). When I use the same code as above, I get an error saying that I should usecoeff
instead. Is there a way to "translate" the above mentioned contrast tocoeff
? Thank youWe can't do numeric contrasts with apeglm, but you can with ashr, see here:
https://bioconductor.org/packages/release/bioc/vignettes/DESeq2/inst/doc/DESeq2.html#extended-section-on-shrinkage-estimators
Thank you very much! This was super helpful