Thank you! This helped!
If I did have samples with different tissues as well should I call:
so <- sleuth_fit(so, ~ Tissue, ~ Condition, 'full')
so <- sleuth_fit(so, ~ 1, 'reduced')
Does anyone have the solution to this error message?
I am working with Kallisto and Sleuth to analyze some RNA seq data. I have a control set of macula data and a set of macula data with AMD. I am trying to analyze differential gene expression between the two sets.
Design table:
sample Tissue Condition
AMD_macula.11 Macula AMD
AMD_macula.12 Macula AMD
AMD_macula.14 Macula AMD
AMD_macula.17 Macula AMD
AMD_macula.18 Macula AMD
AMD_macula.19 Macula AMD
ctrl_macula.10 Macula nodisease
ctrl_macula.13 Macula nodisease
ctrl_macula.15 Macula nodisease
ctrl_macula.16 Macula nodisease
ctrl_macula.4 Macula nodisease
ctrl_macula.6 Macula nodisease
I have created my sleuth object and now I am trying to fit the models so I can run linear regression and wald tests.
so <- sleuth_fit(so, ~sample + Condition,'full')
so <- sleuth_fit(so, ~Tissue, 'Tissue')
models(so)
When running these, I cannot get past creating the first model because I am getting this error that is saying that the system is computationally singular.
> so <- sleuth_fit(so, ~sample + Condition,'full')
Error in solve.default(t(X) %*% X) :
system is computationally singular: reciprocal condition number = 3.82836e-18
Does anyone know how to solve this? I believe something is wrong with my design table, but I cannot think of how to fix it.
Thanks!
Is "sample" just a unique sample identifier?? Then it should not be included as a batch variable and you should drop it from your sleuth_fit call. Also why are you including tissue if they are all from the same tissue, if there is no variability then there is no point in including it as a batch variable.. A meaningful batch variable should be a factor variable with multiple samples per factor.
Try:
so <- sleuth_fit(so, ~ Condition, 'full')
so <- sleuth_fit(so, ~ 1, 'reduced')
Thank you! This helped!
If I did have samples with different tissues as well should I call:
so <- sleuth_fit(so, ~ Tissue, ~ Condition, 'full')
so <- sleuth_fit(so, ~ 1, 'reduced')
If an answer was helpful you should upvote it, if the answer resolved your question you should mark it as accepted.

The full model should only be testing the effect of condition not Tissue + condition, so you would need to add Tissue to the reduced model.
so <- sleuth_fit(so, ~ Tissue, ~ Condition, 'full')
so <- sleuth_fit(so, ~ Tissue, 'reduced')
Thank you! The help is much appreciated!
Log in to answer this question.
It seems that there is a problem with the code. And I see you already posted something over Sleuth's google group. I think the best option here is to wait for the sleuth's development team to give you some advice