View Single Post
Old 04-27-2016, 06:51 AM   #5
illinu
Member
 
Location: US

Join Date: Jul 2013
Posts: 55
Default

Thank you, I would like to know why the second option is statistically incorrect.

And for sanity could you or someone confirm that this is the correct code in R (DESeq2 package):

Code:
countData=read.table(file.choose(),header=TRUE,row.names=1,sep="\t")
condition=rep(rep(c("Ctr","Treat"),each=3),4)
genotype=rep(rep(c("A","B"),each=6),2)
colData=data.frame(condition,genotype,row.names=names(countData))
dds <- DESeqDataSetFromMatrix(countData = countData,colData = colData,design = ~ condition+genotype)
ddsM=dds
design(ddsM) <- formula(~condition*genotype)
ddsM <- DESeq(ddsM)
resM <- results(ddsM)
ddsMN=ddsM
ddsMN = estimateSizeFactors(ddsM)
ddsMN = estimateDispersions(ddsM)
resGenotype=nbinomLRT(ddsMN, full = design(ddsM), reduced =  formula(~condition*genotype), maxit = 1000)
resGenotype <- results(resMTolFact, contrast=c("genotype","A","B"))
illinu is offline   Reply With Quote