Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error in the final step (R): 'by' appears to evaluate to column names but isn't c() or key()' #20

Open
Giuseppe1995 opened this issue May 17, 2022 · 1 comment

Comments

@Giuseppe1995
Copy link

Hi, I am trying to run fragCount as follows:

frag -b SP_1_N/SP_1_N.finalSorted.bam -w 1000 -d /srv/ngs/analysis/dalteriog/reference_genomes/hs/mapFiles -o SvABA_dir

where /srv/ngs/analysis/dalteriog/reference_genomes/hs/mapFiles is the directory where I put both gc1000.rds and map1000 files.
It seems to proceed regularly at the beginning, but the trouble starts when it runs R script. Here is the standard error starting from the R part:

Finished computing coverage, and making GRanges
Finished acquiring coverage
Loaded GC and mappability
length cov is 3095706, length gc is 3074148, length map is 3074148
Synced coverage, GC, and mappability
Modified gc / mappability correction
Converting to data.table
Grouping intervals
Defining 100 fold collapsed ranges
Presegmenting at NA bp scale
Error in [.data.table(cov.dt, , list(chr = seqnames[1], start = min(start), :
'by' appears to evaluate to column names but isn't c() or key(). Use by=list(...) if you can. Otherwise, by=eval(get(paste("lev", numlevs, sep = ""))) should work. This is for efficiency so data.table can detect which columns are needed.
Calls: fragCounter -> multicoco -> seg2gr -> is -> [ -> [.data.table
In addition: Warning messages:
1: replacing previous import 'GenomicRanges::shift' by 'data.table::shift' when loading 'bamUtils'
2: replacing previous import 'GenomicAlignments::second' by 'data.table::second' when loading 'bamUtils'
3: replacing previous import 'GenomicAlignments::last' by 'data.table::last' when loading 'bamUtils'
4: replacing previous import 'GenomicAlignments::first' by 'data.table::first' when loading 'bamUtils'
5: In for (i in seq_len(n)) { :
closing unused connection 3 (SP_1_N/SP_1_N.finalSorted.bam)
6: In max(width(cov)) : no non-missing arguments to max; returning -Inf
7: In cat("Presegmenting at ", as.integer(WID * base^(numlevs)), " bp scale \n") :
NAs introduced by coercion to integer range
Execution halted

in my output directory (SvABA_dir) it gives me these outputs:
ls SvABA_dir

cmd.args cmd.args.rds

and i tried to check if there was something wrong in the cmd.args file. Here comes the output:

cat SvABA_dir/cmd.args

--bam SP_1_N/SP_1_N.finalSorted.bam --midpoint TRUE --window 1000 --gcmapdir /srv/ngs/analysis/dalteriog/reference_genomes/hs/mapFiles --minmapq 1 --paired TRUE --exome FALSE --use.skel FALSE --outdir SvABA_dir --libdir /isva --help FALSE

Thank you so much for your help!

Giuseppe

Post Scriptum: I am sorry but I wrongly posted this issue in the JaBba page issue section. I got confused. Sorry again.

@roseisgold
Copy link

Hey!! I am getting the same error that you posted above--did you find any solutions to this issue?

Thank you :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants