Hi Mike,
I am using DESeq2 to analyze differential translation efficiency (TE) from Ribosomal profiling (Riboseq) and RNAseq datasets. Translation efficiency = normalized Riboseq read density / normalized RNASeq read density. I have four groups of samples with duplicates each group for both Riboseq and RNAseq: 1) wild type in physiological condition, 2) wild type in stress condition, 3) mutant in physiological condition, and 4) mutant in stress condition. We aim to identify gene lists where those genes have significantly changed translation efficiency (TE) between different conditions. There are helpful posts giving me examples for just comparing TE between single factor, such as treatment vs control: DESeq2 for Ribosomal profiling analysis (design = ~SeqType + Genotype + SeqType:Genotype).
However, when there are two factors, such as "WT and mutant" plus "Treatment and control", Can we use DESeq2 for TE analysis? Shall I divide them into two single-factor-analyses, or I can combine them into one two-factor analysis using
> design(dds) ~SeqType + Genotype + Stress + seqType:Genotype + seqType:Stress
Exp. Desgin |
SeqType |
Genotype |
Stress |
Ribo_WT_CTL |
Riboseq |
WT |
CTL |
Ribo_WT_Stress |
Riboseq |
WT |
Stress |
Ribo_mutant_CTL |
Riboseq |
mutant |
CTL |
Ribo_ mutant _Stress |
Riboseq |
mutant |
Stress |
RNA_WT_CTL |
RNAseq |
WT |
CTL |
RNA_WT_Stress |
RNAseq |
WT |
Stress |
RNA_ mutant _CTL |
RNAseq |
mutant |
CTL |
RNA_ mutant _Stress |
RNAseq |
mutant |
Stress |
If using design = ~ SeqType + Genotype + Stress + SeqType:Genotype + SeqType:Stress
, how can I get specific set of TE comparison between the following groups?
1) TE_WT_Stress vs TE_WT_CTL:
a1 <- results(dds, contrast=list("SeqType_Riboseq_vs_Rnaseq", "Stress_Stress_vs_CTL", SeqType.Genotype")))
2) TE_Mutant_Stress vs TE_Mutant_CTL:
a2 <- results(dds, contrast=list("SeqType_Riboseq_vs_Rnaseq", "Stress_Stress_vs_CTL", SeqType.Genotype_Mutant")))
3) TE_Mutant_CTL vs TE_WT_CTL:
a3 <- results(dds, contrast=list("SeqType_Riboseq_vs_Rnaseq", "Genotype_mutant_vs_WT", SeqType.Stress")))
4) TE_Mutant_Stress vs TE_WT_Stress:
a4 <- results(dds, contrast=list("SeqType_Riboseq_vs_Rnaseq", "Genotype_mutant_vs_WT", SeqType.Stress_Stress")))
Apologies if this is full of mistake and confusing.
Thanks for the help!
Best,
Xiaozhuo
hi Mike,
Great! Thanks for your help as always! For "grouping" function, I notice you had another helpful post before: https://support.bioconductor.org/p/67600/#67612 (DESEq2 comparison with mulitple cell types under 2 conditions). Following this post and reply, here is the code for "grouping" and getting the Ribo/RNA ratio across groups,
1) Could you tell me whether the code is correct for the Ribo/RNA ratio?
Note: The code
coldata$group <- factor(paste0(coldata$genotype, coldata$Stress))
didn't work for my case, so I useddds$group <- factor(paste0(dds$Genotype, dds$Stress))
instead.And here is the
resultsNames(dds)
output lists given by this code:"Intercept", "group_MutantStress_vs_MutantCTL", "group_WTCTL_vs_MutantCTL", "group_WTStress_vs_MutantCTL", "groupMutantCTL.SeqTypeRiboseq", "groupMutantStress.SeqTypeRiboseq", "groupWTCTL.SeqTypeRiboseq", "groupWTStress.SeqTypeRiboseq"
# e.g. TE_WT_Stress vs TE_WT_CTL:
# e.g. TE_Mutant_Stress vs TE_Mutant_CTL:
# e.g. TE_Mutant_CTL vs TE_WT_CTL:
# e.g. TE_Mutant_Stress vs TE_WT_Stress:
Again, thanks for your time and support!
Best,
Xiaozhuo
Hi Michael,
Sorry to bother on such an old question, but I have something similar data as Xiaozhuo above but a further question have. Our data have all factors above (SeqType, Genotype, Stress) and another factor for animal sex (Sex). We want to find differences in Ribo/RNA ratio across groups, but we also want to know differences between the Ribo/RNA ratio in Stress condition vs Ctrl condition within different groups (group is sex*genotype here I mean).
If we're to make 'group' as suggested above, would we group all of Genotype, Stress, and Sex? Or, would we only group Genotype and Sex?
The example you provide above for
~group+group:type
makes sense for pulling out Ribo/RNA ratios compared between two groups (group=Genotype*Stress). But, is there a good way to then compare Ribo/RNA between the different groups with respect to different Stress conditions? Would this be possible by using with model~group+group:type+group:type:stress
and contrasting with the three-way interaction term? Or, will I have to make multiple grouping variables to ask these two different questions with the same model? I understand the two-way intxn term above is 'ratio of ratios', but it is a little harder for wrap my head around that plus another ratio, if that makes sense.edit: or, would it be more appropriate to make 'group' be the distinct intersection of all factors, and then compare Ribo/RNA for group by making the numerator the mean of the 'groups' with Ribo, and denominator mean of the 'groups' with RNA? And continue in that way for then the stress condition differences as above? Does that make sense?
Thank you for help! Best, Ananda
hi Ananda,
This is pretty complicated, and there are actually many choices to make here. The choices are more about the assumptions of your model, so I'd recommend that you consult with a statistician. As you can imagine, I have limited time for statistical analysis and design questions on the support website, but have to limit to software issues.