cnv_facets
cnv_facets copied to clipboard
Error in 1:nchr : result would be too long a vector
Hi Dariober
when I run with unmatched mode (the unmatched bam are merged from 10 un-related normal samples)
cnv_facets.R
-t ./bams/S21-096.bam
-n merged_normal.bam
--unmatched
-vcf vcfs/S21-096.hard-filtered.vcf.gz \
--targets Illumina_Exome_TargetedRegions_v1.2.hg38.bed
--out cnv_results_normal/S21-096
for some samples, I got error below, do you have any comments?
[2023-08-12 20:46:33] Preprocessing sample... Error in 1:nchr : result would be too long a vector Calls: run_facets -> preProcSample -> counts2logROR In addition: Warning message: In max(mat$chrom) : no non-missing arguments to max; returning -Inf Execution halted
thanks in advance Jeff C
Hi- It's hard to tell what is happening without seeing more of the data. Check that chromosome names are consistent across the input files. Also have a look at the pileup file, which should be in cnv_results_normal
for anything odd (perhaps post here a sample of it).
I ran into this error when the --depth
(min depth) was higher than what any of the candidates had. That leads to this line: https://github.com/dariober/cnv_facets/blob/44fdd18a4beb4f57c6e6e746d31a6399efdbc85b/bin/cnv_facets.R#L817 producing an empty table, leading to an error here: https://github.com/mskcc/facets/blob/f3c93ee65b09fc57aaed22a2eb9faa05586a9dc0/R/facets-procreads.R#L50-L51 - because there is no data there, the max fails, causing an issue in the following loop.
Perhaps this could be helped with a check after https://github.com/dariober/cnv_facets/blob/44fdd18a4beb4f57c6e6e746d31a6399efdbc85b/bin/cnv_facets.R#L817, verifying that there's data left in the table?