Description Usage Arguments Details Value See Also Examples
View source: R/deduplication_functions.R
Removes duplicates using sensible defaults
1 | deduplicate(data, match_by, method, type = "merge", ...)
|
data |
A |
match_by |
Name of the column in |
method |
The duplicate detection function to use; see see |
type |
How should entries be selected? Default is |
... |
Arguments passed to |
This is a wrapper function to find_duplicates
and extract_unique_references
, which tries to choose some sensible defaults. Use with care.
A data.frame
containing data identified as unique.
find_duplicates
and extract_unique_references
for underlying functions.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 | my_df <- data.frame(
title = c(
"EviAtlas: a tool for visualising evidence synthesis databases",
"revtools: An R package to support article screening for evidence synthesis",
"An automated approach to identifying search terms for systematic reviews",
"Reproducible, flexible and high-throughput data extraction from primary literature",
"eviatlas:tool for visualizing evidence synthesis databases.",
"REVTOOLS a package to support article-screening for evidence synthsis"
),
year = c("2019", "2019", "2019", "2019", NA, NA),
authors = c("Haddaway et al", "Westgate",
"Grames et al", "Pick et al", NA, NA),
stringsAsFactors = FALSE
)
# run deduplication
dups <- find_duplicates(
my_df$title,
method = "string_osa",
rm_punctuation = TRUE,
to_lower = TRUE
)
extract_unique_references(my_df, matches = dups)
# or, in one line:
deduplicate(my_df, "title",
method = "string_osa",
rm_punctuation = TRUE,
to_lower = TRUE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.