Traverses concept_ancestor. SQL lives in inst/sql/getConceptDescendants.sql.

getConceptDescendants(
  conceptIds,
  connection,
  vocabularyDatabaseSchema,
  minLevels = 0L,
  maxLevels = Inf
)

Arguments

conceptIds

Integer vector of standard concept IDs.

connection

A DatabaseConnector connection to an OMOP CDM.

vocabularyDatabaseSchema

Schema containing the OMOP vocabulary tables. Required.

minLevels

Minimum levels of separation (default 0 includes seeds).

maxLevels

Maximum levels of separation (default Inf = all descendants).

Value

A tibble with concept details plus min/max_levels_of_separation.

See also

searchConcepts, descendants, cs

Examples

if (FALSE) {
connection <- DatabaseConnector::connect(Eunomia::getEunomiaConnectionDetails())
getConceptDescendants(313217L, connection, vocabularyDatabaseSchema = "main")
}