RahmanTeam / DECoN

50 stars 29 forks source link

Error in makeCNVcall.R #19

Open robertosirica opened 4 years ago

robertosirica commented 4 years ago

Hello, I'm trying to run DECoN on Fedora, I followed the procedure in the manual and created the R image to load as input in the command in object, I just launched the command below: /R-3.4.2/bin/Rscript makeCNVcalls.R --transProb 0.01 --Rdata test.out.RData --plot All --custom FALSE --plotFolder out_F

after computing all the CNV calls it gives me this error:

There were 13 warnings (use warnings() to see them) Error in cnv.calls_ids[i, ]$start.p:cnv.calls_ids[i, ]$end.p : result would be too long a vector Inoltre: Warning messages: 1: In min(overlap) : no non-missing arguments to min; returning Inf 2: In max(overlap) : no non-missing arguments to max; returning -Inf 3: In min(overlap) : no non-missing arguments to min; returning Inf 4: In max(overlap) : no non-missing arguments to max; returning -Inf 5: In min(overlap) : no non-missing arguments to min; returning Inf 6: In max(overlap) : no non-missing arguments to max; returning -Inf execution interrupted

What could be causing the error?

Thank you

alejandroriglesias commented 4 years ago

Hello! I got the same error. Were you able to solve it?

Thank you!

robertosirica commented 4 years ago

Hello Alejandro, no I wasn't able to solve it, I hope someone has a workaround to make it run. Best Regards

alejandroriglesias commented 4 years ago

Thanks Roberto. We think it's a memory problem ("result would be too long a vector"), but we cannot find any information about it. If you can finally solve it, let us know please. Thanks!

eriktoo commented 4 years ago

Hello @robertosirica and @alejandroriglesias ,

I encountered the same error. After spinning my wheels for a while I tracked down the code in 'makeCNVcalls.R'. It is part of a for loop that 'replaces single calls involving multiple genes with multiple calls with single call ID'. My bed file was generated by CNVkit and the fourth column consists of gene names, as required, but for some intervals there are multiple genes separated by comma. When I removed all but one gene name 'makeCNVcalls.R' completed, albeit with warnings. Warnings are not printed by default, but if you want to see them you can add warnings() to the end of the relevant script - I put it just before the last line which prints "END makeCNVCalls.R".

The warnings I saw were 16x 'The plyr::rename operation has created duplicates for the following name(s): (size)'.

Hope this is helpful.

-Erik

robertosirica commented 3 years ago

Thank you @eriktoo I tried your solution and it works but after a long time running it stops. Do you have all the plots as output? How many samples did you process? Thank you

eriktoo commented 3 years ago

Hi @robertosirica

I have plots for each CNV recorded in the DECoNResults_all.txt file. For testing purposes I was only working with 5 samples, and am sequencing with small targeted panel of ~45 genes albeit at high coverage (~2000x). Ultimately I've decided not to move forward with DECoN since it does not appear to perform well with my panel, and have not tried scaling up to larger sample sets. I was running it in a small VM with two vCores and 4G RAM and for 5 samples it took about 20-30 minutes to complete all analysis steps. If you're processing a lot of samples maybe memory usage is an issue?

Thanks, Erik