Creates a local omop_concept_set object that defines a set of OMOP
concepts along with expansion rules. This is a client-side-only helper
that does not contact any server; the resulting object is passed to
ds.omop.concept.expand for server-side resolution.
Usage
ds.omop.concept.set(
concepts,
include_descendants = FALSE,
include_mapped = FALSE,
exclude = NULL
)Arguments
- concepts
Integer or numeric vector of seed concept IDs that form the base of the concept set.
- include_descendants
Logical; if
TRUE, all descendants of the seed concepts (viaconcept_ancestor) will be included when the set is expanded. Default:FALSE.- include_mapped
Logical; if
TRUE, non-standard concepts mapped to the seed concepts (viaconcept_relationship) will be included when the set is expanded. Default:FALSE.- exclude
Integer or numeric vector of concept IDs to explicitly remove from the expanded set.
NULL(the default) excludes nothing.
Examples
if (FALSE) { # \dontrun{
# Simple concept set with descendants
cs <- ds.omop.concept.set(c(201826, 316139), include_descendants = TRUE)
# Expand the concept set on the server
expanded <- ds.omop.concept.expand(cs)
} # }