**0**wrote:

Hi,

I am finding an error with estimateDispersions() in DESeq2.

In my experimental design I have 3 factors: Treatment, Time and Depth

I start with a phyloseq object (PHYLUM) that I convert to DESeq (Phylum)

easily, including two of the factors in the design.

> Phylum=phyloseq_to_deseq2(PHYLUM,~ Time + Treatment)

> Phylum

class: DESeqDataSet

dim: 57 30

exptData(0):

assays(1): counts

rownames(57): OTU1 OTU2 ... OTU56 OTU57

rowData metadata column names(0):

colnames(30): T2_SF5C T25_SF1B ... T2_DP1A T2_DP1C

colData names(3): Treatment Time Depth

> colData(Phylum)

DataFrame with 30 rows and 3 columns

Treatment Time Depth

<factor> <factor> <factor>

T2_SF5C DOMNP 02d 25m

T25_SF1B C 25d 25m

T25_SF5B DOMNP 25d 25m

T25_SF4A DOM 25d 25m

T2_SF4A DOM 02d 25m

... ... ... ...

T25_DP5A DOMNP 25d 125m

T25_DP4B DOM 25d 125m

T25_DP5B DOMNP 25d 125m

T2_DP1A C 02d 125m

T2_DP1C C 02d 125m

All contrasts work fine with this design (~ Time + Treatment).

The problem comes when I try to perform interactions. I find and error when estimating dispersions (see below). Do you know how can I solve it? Is it related to the nature of my factors?

I have seen a previous post in which the same error was discussed but in that case the problem was the opposite: the error occurred with the normal contrast and was solved in the interaction. I am using DESeq 1.4.5.

Thanks so much!!!!

> design(Phylum) <- ~ Time + Treatment + Time:Treatment

> Phylum<-estimateSizeFactors(Phylum)

> Phylum<-estimateDispersions(Phylum,fitType="local")

gene-wise dispersion estimates

error: inv(): matrix appears to be singular

Error: inv(): matrix appears to be singular