jaleesr / TrendCatcher

TrendCatcher is an open source R-package that allows users to systematically analyze and visualize time course data. Please cite "Temporal transcriptomic analysis using TrendCatcher identifies early and persistent neutrophil activation in severe COVID-19" by Xinge Wang et al published in JCI Insight (2022) - https://insight.jci.org/articles/view/157255
9 stars 3 forks source link

gss error Issue with three time point samples #1

Closed kanekalla closed 2 years ago

kanekalla commented 2 years ago

Hi there,

Thank you for a great package for time series analysis. I was able to process my samples that had four time points but I was unable to process my samples with three time points. when I run run_TrendCatcher I am getting the following error.

Read count table. Passed Format Check. Count table is 12 Samples, 8780 Genes Found 101 low count genes. Count table format correct, finished loading. gene-wise dispersion estimates mean-dispersion relationship final dispersion estimates Run TrendCatcher. `| | 0%Warning in .Internal(gc(verbose, reset, full)) : closing unused connection 13 (<-localhost:11350) Warning in .Internal(gc(verbose, reset, full)) : closing unused connection 12 (<-localhost:11350) Warning in .Internal(gc(verbose, reset, full)) : closing unused connection 11 (<-localhost:11350) Warning in .Internal(gc(verbose, reset, full)) : closing unused connection 10 (<-localhost:11350) Warning in .Internal(gc(verbose, reset, full)) : closing unused connection 9 (<-localhost:11350) Warning in .Internal(gc(verbose, reset, full)) : closing unused connection 8 (<-localhost:11350) Warning in .Internal(gc(verbose, reset, full)) : closing unused connection 7 (<-localhost:11350) Warning in .Internal(gc(verbose, reset, full)) : closing unused connection 6 (<-localhost:11350) Warning in .Internal(gc(verbose, reset, full)) : closing unused connection 5 (<-localhost:11350) Warning in .Internal(gc(verbose, reset, full)) : closing unused connection 4 (<-localhost:11350) Warning in .Internal(gc(verbose, reset, full)) : closing unused connection 3 (<-localhost:11350) |=================================================================| 100%Timing stopped at: 5.052 1.569 29.84  Show Traceback

Error in { : task 3 failed - "gss error in gssanova: unpenalized terms are linearly dependent"`

I would appreciate if you can point me to where the error is coming from ? Is it something with gss package ?

wangxinge commented 2 years ago

Hello Anekallav, Thank you very much using TrendCatcher. This error comes from gss fitting process, it is very likely caused by a gene that has all 0 count through all the time points. Please use rowSums to check which gene has the super low count and remove it from your count table. Then re-run TrendCatcher.

kanekalla commented 2 years ago

Hi @wangxinge ,

That is what I thought based on the initial error thrown. But, I tested by removing all the genes with nearly zero counts. To test I made a stringent cutoff and here is the data frame with rowsum info, even then I am oberving the following error. Screen Shot 2022-01-22 at 4 25 56 PM

Can you kindly look at it ?

wangxinge commented 2 years ago

Dear @kanekalla , I've added a show.verbose option in run_TrendCatcher. If you set it to TRUE, it will print gene name which has been successfully processed by gss package. Check the gene name which failed the fitting and you can remove it from your count table.

kanekalla commented 2 years ago

Hi @wangxinge , thanks for adding verbose option, but despite removing the gene its picking the next gene to be error prone although the read counts are highly expressed

Screen Shot 2022-01-29 at 9 47 02 AM Screen Shot 2022-01-29 at 9 46 22 AM Screen Shot 2022-01-29 at 9 49 47 AM

.

wangxinge commented 2 years ago

Hi @kanekalla, this error is due to your data failed to fitting into the gssanova model, due to the "linearly dependent". This happens very rarely, the error catching version will be updated soon, before that, please manually remove it from your count table.

wangxinge commented 2 years ago

Hi @kanekalla, another reason you may keep this error is you set your baseline.t in the main function to default, which is 0. However, in your case, it should be 2.

kanekalla commented 2 years ago

Hi @wangxinge , thanks for that , I changed the baseline time point and it worked. I appreciate your help.