Error in estimateDispersions of DEXSeq
1
0
Entering edit mode
@deeyasaha86-7123
Last seen 10.0 years ago
United States

Sir,

While running DEXSeq on a Human dataset, (commands given below), I get the following error.

> countFiles=list.files(inDir,pattern="fb.txt$",full.names=TRUE)
>flattenedFile=list.files(inDir,pattern="gff$",full.names=TRUE)
>sampleTable=data.frame(row.names=c("treated1","treated2","treated3","untreated1","untreated2","untreated3"),condition=c("knockdown","knockdown","knockdown","control","control","control"),libType=c("paired-end","paired-end","paired-end","paired-end","paired-end","paired-end"))
>library("DEXSeq")
>dxd=DEXSeqDataSetFromHTSeq(countFiles,sampleData=sampleTable,design=~sample+exon+condition:exon,flattenedfile=flattenedFile )
>dxd_esf=estimateSizeFactors(dxd)
>dxd_ed=estimateDispersions(dxd_esf)




>dxd_ed=estimateDispersions(dxd_esf,fitType="mean")

#using supplied model matrix
#Error in estimateDispersionsFit(object, fitType = fitType, quiet = quiet) :
#  all gene-wise dispersion estimates are within 2 orders of magnitude
#from the minimum value, and so the standard curve fitting techniques will not work.
#You can instead use the gene-wise estimates as final estimates:
#dds <- estimateDispersionsGeneEst(dds)
#dispersions(dds) <- mcols(dds)$dispGeneEst
I tried using a smaller subset of geneset, but to no avail.

genesForSubset=read.table(file.path(inDir,"Human_IDC.txt"),stringsAsFactors=FALSE)[[1]]
dxd=dxd[geneIDs( dxd )%in%genesForSubset,]
>dxd_ed=estimateDispersions(dxd_esf,fitType="mean")
using supplied model matrix
Error in estimateDispersionsFit(object, fitType = fitType, quiet = quiet) :
  all gene-wise dispersion estimates are within 2 orders of magnitude
from the minimum value, and so the standard curve fitting techniques will not work.
You can instead use the gene-wise estimates as final estimates:
dds <- estimateDispersionsGeneEst(dds)
dispersions(dds) <- mcols(dds)$dispGeneEst


Even, I tried using (estimateDispersionsGeneEst(dds) on dxd_esf object, but landed up with the following error.

dds <- estimateDispersionsGeneEst(dxd_esf)
#error: inv(): matrix appears to be singular

#Error: inv(): matrix appears to be singular

Please suggest a way out.

DEXSeq estimateDispersions • 3.3k views
ADD COMMENT
0
Entering edit mode
@mikelove
Last seen 13 hours ago
United States

This check occurs in DESeq2, where all the gene wise dispersion values are less than 1e-6, where the minimal value is 1e-8. Then it would be problematic to fit a dispersion trend. The reason for a minimal value, is that for a given row of the count matrix, the maximum likelihood estimate can tend to 0 (and so we have a rule to stop after 1e-8). Is there something special about this dataset, why the counts are not overdispersed? Typically with biological replicates, we observe overdispersion in gene or exon counts. If you plot the counts of one sample against another (in log scale), do all the points fall on a diagonal line?

ADD COMMENT

Login before adding your answer.

Traffic: 869 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