-
Notifications
You must be signed in to change notification settings - Fork 0
20171226
2017/12/26
While we have been running log2 difference across different conditions pair-wisely. But on "https://bioconductor.org/packages/3.7/bioc/vignettes/DESeq2/inst/doc/DESeq2.html#if-i-have-multiple-groups-should-i-run-all-together-or-split-into-pairs-of-groups" On the document, it suggests "Typically, we recommend users to run samples from all groups together, and then use the contrast argument of the results function to extract comparisons of interest after fitting the model using DESeq."
Running the steps 1 to 2 posted on "20171212" for spiked in *Step 3 changing to nbinomWaldTest instead, because not comparing between full vs reduced model
RNASeqDDS_nbinomWald<-nbinomWaldTest(RNASeqDDS_dispersion)
Step 4 for calculating WALD p-values for each pair comparison, e.g.:
- For WT vs DICERKO
spikedin_RNASeqres_WTvsDICERKO<-results(RNASeqDDS_nbinomWald,contrast=c("conds","WT","DICERKO"))
The codes are run similarly for TTseq -For consistent column names between RNASeq and TTSeq
colnams(TTseq)<-c("WT_1","WT_2","AGO2KO_1","AGO2KO_2","DICERKO_1","DICERKO_2")
rownames(TTseq)<- TTseq[,1]
TTseq<- TTseq[,-1]
-DSeq
TTSeqDDS<-DESeqDataSetFromMatrix(countData = TTseq,colData = DataFrame(conds),design=~conds)
sizeFactors(TTSeqDDS)<-c(342.423499311214,128.641601679064,446.656668972049,196.179761943702,640.856763252764,116.620347681329)
TTSeqDDS_dispersion<-estimateDispersions(TTSeqDDS)
TTSeqDDS_nbinoWald<-nbinomWaldTest(TTSeqDDS_dispersion)
When running lfcShrink and with "coeff", it will automatically take the AGO2KO as the baseline condition because it is the first alphabetically "https://support.bioconductor.org/p/98833/" Thus, while running lfcShrink using contrast, one needs to be careful of the order, as the following: "the name of a factor in the design formula, the name of the numerator level for the fold change, and the name of the denominator level for the fold change"
Reason of using lfcShrink: https://stat.ethz.ch/pipermail/bioconductor/2013-July/053990.html
-> Choose WT as the baseline (i.e. set it as the denominator)
WT vs DICERKO
WT vs AGO2KO
For the two mutants comparison, use AGO2KO as baseline: AGO2KO vs DICERKO
PLOTS:
- plotMA