restrictToCodesInUse | R Documentation |
Filter a codelist to keep only the codes used in the database
restrictToCodesInUse(
x,
cdm,
table = c("condition_occurrence", "device_exposure", "drug_exposure", "measurement",
"observation", "procedure_occurrence", "visit_occurrence")
)
x |
A codelist |
cdm |
cdm_reference via CDMConnector |
table |
cdm table |
A list of integers indicating the codes used in the database
## Not run:
cdm <- mockVocabRef("database")
codes <- getCandidateCodes(cdm = cdm,
keywords = "arthritis",
domains = "Condition",
includeDescendants = FALSE)
x <- restrictToCodesInUse(list("cs1" = codes$concept_id,
"cs2" = 999),
cdm = cdm)
x
CDMConnector::cdmDisconnect(cdm)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.