What happens when estimateSizeFactors() is added to the standard workflow before DESeq()?
1
0
Entering edit mode
@megapode32559-23129
Last seen 4.7 years ago
dds <- DESeqDataSetFromMatrix(countData = cts,
                              colData = coldata,
                              design= ~ batch + condition)
# dds <- estimateSizeFactors(dds)
dds <- DESeq(dds)
resultsNames(dds) # lists the coefficients
res <- results(dds, name="condition_trt_vs_untrt")
# or to shrink log fold changes association with condition:
res <- lfcShrink(dds, coef="condition_trt_vs_untrt", type="apeglm")

In the above code, if dds <- estimateSizeFactors(dds) is uncommented, I see the results are different. How does it affect the results? Thanks.

deseq2 • 696 views
ADD COMMENT
0
Entering edit mode
@mikelove
Last seen 11 hours ago
United States

The message tells you what happens:

> dds <- makeExampleDESeqDataSet()
> dds <- estimateSizeFactors(dds, controlGenes=1:50)
> dds <- DESeq(dds)
using pre-existing size factors
estimating dispersions
gene-wise dispersion estimates
mean-dispersion relationship
final dispersion estimates
fitting model and testing

It uses the pre-existing sizeFactors(dds) however they were created (or simply assigned).

ADD COMMENT

Login before adding your answer.

Traffic: 731 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6