Learn R Programming

CodelistGenerator (version 3.5.0)

compareCodelists: Compare overlap between two sets of codes

Description

Compare overlap between two sets of codes

Usage

compareCodelists(codelist1, codelist2)

Value

Tibble with information on the overlap of codes in both codelists.

Arguments

codelist1

Output of getCandidateCodes or a codelist

codelist2

Output of getCandidateCodes.

Examples

Run this code
# \donttest{
cdm <- mockVocabRef()
codes1 <- getCandidateCodes(
 cdm = cdm,
 keywords = "Arthritis",
 domains = "Condition",
 includeDescendants = TRUE
)
codes2 <- getCandidateCodes(
 cdm = cdm,
 keywords = c("knee osteoarthritis", "arthrosis"),
 domains = "Condition",
 includeDescendants = TRUE
)
compareCodelists(
 codelist1 = codes1,
 codelist2 = codes2
)
# }

Run the code above in your browser using DataLab