Description Usage Arguments See Also Examples
amerge
merges two datasets by exact keys and filter out rows that do not approximately match by given string keys.
1 |
x |
A data.frame or data.table. |
y |
A data.frame or data.table. |
aby |
name of a string key for approximate matching |
method |
Method for distance calculation. |
tol |
tolerance of dissimilarity between string keys in matched datasets |
p |
see |
... |
other parameters passed to |
merge
, stringdist
and stringsim
1 2 3 4 5 6 7 8 9 | dt1 <- data.table(id = c(1, 2, 3, 4, 5),
name = c("Aple", "Google inc.", "ABB", "Sun", "Sony"),
value = rnorm(5))
dt2 <- data.table(id = c(1, 2, 3, 4, 5),
name = c("Apple", "Google", "BBC", "Sun Microsystems", "Sony Corporation"),
value = rnorm(5))
amerge(dt1, dt2, by = "id", aby = "name", tol = 0.3)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.