We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Submitted by: Garrett See; Assigned to: Nobody; R-Forge link
When using "not joins", j is not evaluated for each row of i. This behavior is consistent with the old not-join idiom; i.e. not a new bug.
j
i
DT = data.table(x=rep(c("a","b","c"),each=3), y=c(1,3,6), v=1:9) setkey(DT,x) DT[!J("a"), sum(y)] # [1] 20 DT[!"a", sum(y)] # [1] 20
This is no different than the old way, so it is "expected" behavior:
DT[-DT["a", which=TRUE, nomatch=0], sum(y)] # [1] 20
But since !"a" is the same as c("b", "c"),
!"a"
c("b", "c")
identical(DT[!J("a")], DT[J(c("b", "c"))]) # TRUE # [1] TRUE
I would have expected it to be the same as joining the columns other than "a":
DT[J(c("b", "c")), sum(y)] # x V1 #1: b 10 #2: c 10 DT[c("b", "c"), sum(y)] # x V1 #1: b 10 #2: c 10
The text was updated successfully, but these errors were encountered:
569fbf3
No branches or pull requests
Submitted by: Garrett See; Assigned to: Nobody; R-Forge link
When using "not joins",
j
is not evaluated for each row ofi
. This behavior is consistent with the old not-join idiom; i.e. not a new bug.This is no different than the old way, so it is "expected" behavior:
But since
!"a"
is the same asc("b", "c")
,I would have expected it to be the same as joining the columns other than "a":
The text was updated successfully, but these errors were encountered: