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

integer overflow for large genome #3

Open
zhangrengang opened this issue Oct 21, 2019 · 0 comments
Open

integer overflow for large genome #3

zhangrengang opened this issue Oct 21, 2019 · 0 comments

Comments

@zhangrengang
Copy link

For large genome, I find that:

> queryLenAgg = tapply(alignments$lenAln, alignments$queryID, sum)
There were 12 warnings (use warnings() to see them)
> warnings()
Warning messages:
1: In FUN(X[[i]], ...) : integer overflow - use sum(as.numeric(.))
2: In FUN(X[[i]], ...) : integer overflow - use sum(as.numeric(.))
3: In FUN(X[[i]], ...) : integer overflow - use sum(as.numeric(.))
4: In FUN(X[[i]], ...) : integer overflow - use sum(as.numeric(.))
5: In FUN(X[[i]], ...) : integer overflow - use sum(as.numeric(.))
6: In FUN(X[[i]], ...) : integer overflow - use sum(as.numeric(.))
7: In FUN(X[[i]], ...) : integer overflow - use sum(as.numeric(.))
8: In FUN(X[[i]], ...) : integer overflow - use sum(as.numeric(.))
9: In FUN(X[[i]], ...) : integer overflow - use sum(as.numeric(.))
10: In FUN(X[[i]], ...) : integer overflow - use sum(as.numeric(.))
11: In FUN(X[[i]], ...) : integer overflow - use sum(as.numeric(.))
12: In FUN(X[[i]], ...) : integer overflow - use sum(as.numeric(.))
> queryLenAgg
chr01 chr02 chr03 chr04 chr05 chr06 chr07 chr08 chr09 chr10 chr11 chr12
   NA    NA    NA    NA    NA    NA    NA    NA    NA    NA    NA    NA

Clearly, the summed integer is too large. queryLenAgg = tapply(as.numeric(alignments$lenAln), alignments$queryID, sum) will work.

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

1 participant