I have 12 samples - 3 Controls, 3 T1 , 3 T2 and 3 T3. I am interested in looking at genes that are different between controls and treatment. Also I would like to obtain DE genes that are different between control average and treatment average for which I had provided the contrast above that I want from the analysis (T1 + T2 + T3)/3 - Controls.
I am unable to input such contrasts in the test_differential_abundance function under the contrasts argument.
Can you suggest the design and contrasts arguement for looking at
control vs treatments and
controls average versus treatment average.
In DESeq2 you can pass character, list, or numeric contrasts. Here perhaps easiest would be numeric:
c(-1, 1/3, 1/3, 1/3).
Thank you, Stefano and Michael for the help and also for toning it down for me. That would be comparing mean of controls vs mean treatment.
Another question along the same lines. I am interested in looking at genes that are different between controls and overall treatment. One method that was suggested to me was combine T1,T2,T3 into one and then look at controls versus treatment pairwise comparison. Is there any other way?? How would I compare just the controls versus overall treatment (T1,T2,T3), not taking the average.
I am bad at linear modeling and would appreciate you inputting the answer like above.
To add to the above question. Will similar contrasts control vs overall treatment & control average vs. treatment average work for ordinal values (not leveled factors) . I am not sure if DESeq2 provides support for ordinal values. I have tried with edgeR and limma . They work with ordinal factors well.
Currently, I also have ordinal rank set up in the form of C < T1 < T2 < T3 levels.
The mapping from what you want to a contrast is a long conversation. You can make pairwise comparisons or numeric contrasts or really anything you want. I have to reserve the time I spend on the support site to helping with software-related issues, but I'd recommend you consult with a statistician to decide on what analysis plan you want to take.
You can encode ordinal factors with new variables: e.g.: