-
Notifications
You must be signed in to change notification settings - Fork 979
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
FR: if CJ is passed data.table arguments, do a blocked cross-join #2343
Comments
How about this:
|
I don't see the distinction here. There are two rows in one table; three in the other; and the Cartesian product in the result (regarding rows as tuples and tables as sets of tuples), unless you just mean the row order.
With
Not sure if that's what you're after. I'm not crazy about the row ordering, so I'd probably do Btw, I guess this is related to Jan's CJ.dt #1717 |
Indeed I think #1717 covers this. Closing. |
I have a case where I don't want the outer product of all rows of some input, but rather the outer product of all blocks of rows of the input. It seems natural that
CJ
should be able to handle constructing this:Desired output:
Hopefully it's sufficiently clear from this.
A hack is to do something like:
The order isn't particularly natural here, but doesn't matter in my application. Worse is that it's clunky and not easily extensible to having several more
data.table
s of input.Most natural in current functionality (wrong) is
CJ(DT1$x1, DT1$x2, DT2$y1)
, but this has too many rows and must be pared back.The text was updated successfully, but these errors were encountered: