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 fintersect if the first data table contains a column called "y" #3034

Closed
mnazarov opened this issue Sep 6, 2018 · 2 comments
Closed
Labels
Milestone

Comments

@mnazarov
Copy link
Contributor

mnazarov commented Sep 6, 2018

library(data.table)
dtA <- data.table(y = 1)
dtB <- data.table(y = 2)
fintersect(dtA, dtB)
#> Error in funique(y): is.data.table(x) is not TRUE

The issue is in:

x[funique(y), nomatch=0L, on=names(x), mult="first"]

I guess the solution could be to substitute funique(y) with something like
funique(get("y", envir = parent.frame(3))).

@jangorecki jangorecki added the bug label Sep 6, 2018
@jangorecki jangorecki added this to the 1.11.6 milestone Sep 6, 2018
@jangorecki
Copy link
Member

Thank you for reporting, will fix for coming release.

@MichaelChirico
Copy link
Member

good catch!

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

No branches or pull requests

3 participants