Description Usage Arguments Value Examples
This function can be used when one wants to get exactly the same table but
with some new columns got from a another table. Technically this is equivalent
to a left join without row duplication. Unlike with the default
merge
function, mergeByRef()
does not copy data; it modifies it by reference.
This results in a great performance improvement.
1 2 |
x |
data.table or object inheriting from data.table. |
y |
data.table or object inheriting from data.table. |
by |
Name of columns used for merging. By default, the function uses all common columns. |
colsToAdd |
Name of columns of |
mergeByRef()
modifies its first input by reference so it is used for its
side effects. Nevertheless for convenience it invisibly returns x
with
the new columns appended
1 2 3 4 5 6 7 8 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.