Lookup a Concept Id

get_concept(
  concept_id,
  vocab_schema = "omop_vocabulary",
  conn,
  conn_fun = "connectAthena()",
  cache_only = FALSE,
  skip_cache = FALSE,
  override_cache = FALSE,
  render_sql = FALSE,
  verbose = FALSE,
  sleepTime = 1
)

Value

Concept Class object if the `concept_id` argument is found in the Concept table. If it is not found, nothing is returned.

Examples

#>
#> ── Retrieve Concept Object ─────────────────────────────────────────────────────
#>
#> ── Is Concept Id Valid Integer? ────────────────────────────────────────────────
#> Concept Id is a valid integer
#>
#> ── Lookup Concept Id in Concept Table ──────────────────────────────────────────
#> [2021-05-26 16:00:52] Connected to 'athena' #> [2021-05-26 16:00:52] Postgres connection to 'athena' closed
#> Concept Id `21601787` found in Concept Table
#>
#> ── Lookup Synonyms ─────────────────────────────────────────────────────────────
#> [2021-05-26 16:00:52] Connected to 'athena' #> [2021-05-26 16:00:52] Postgres connection to 'athena' closed
#>
#> ── Lookup 'Maps to' Concept Names ──────────────────────────────────────────────
#> [2021-05-26 16:00:52] Connected to 'athena' #> [2021-05-26 16:00:52] Postgres connection to 'athena' closed
#>
#> ── QA Concept Object ───────────────────────────────────────────────────────────
#> Concept belongs to ATC Vocabulary
#> Concept is an OMOP vocabulary class
#>
#> ── Render & Query ──────────────────────────────────────────────────────────────
#> [2021-05-26 16:00:52] Connected to 'athena' #> [2021-05-26 16:00:52] Postgres connection to 'athena' closed
#> # A tibble: 1 x 10 #> concept_id concept_name domain_id vocabulary_id concept_class_id #> <int> <chr> <chr> <chr> <chr> #> 1 1308216 lisinopril Drug RxNorm Ingredient #> # … with 5 more variables: standard_concept <chr>, concept_code <chr>, #> # valid_start_date <date>, valid_end_date <date>, invalid_reason <chr>
lisinopril_class <- get_concept(concept_id = 21601787)
#>
#> ── Is Concept Id Valid Integer? ────────────────────────────────────────────────
#> Concept Id is a valid integer
#>
#> ── Lookup Concept Id in Concept Table ──────────────────────────────────────────
#> [2021-05-26 16:00:52] Connected to 'athena' #> [2021-05-26 16:00:52] Postgres connection to 'athena' closed
#> Concept Id `21601787` found in Concept Table
#>
#> ── Lookup Synonyms ─────────────────────────────────────────────────────────────
#> [2021-05-26 16:00:52] Connected to 'athena' #> [2021-05-26 16:00:52] Postgres connection to 'athena' closed
#>
#> ── Lookup 'Maps to' Concept Names ──────────────────────────────────────────────
#> [2021-05-26 16:00:52] Connected to 'athena' #> [2021-05-26 16:00:52] Postgres connection to 'athena' closed
lisinopril_class
#> An object of class "concept" #> Slot "concept_id": #> [1] 21601787 #> #> Slot "concept_name": #> [1] "lisinopril; oral" #> #> Slot "concept_synonym_names": #> [1] "lisinopril" #> #> Slot "maps_to_concept_names": #> [1] "lisinopril" #> #> Slot "domain_id": #> [1] "Drug" #> #> Slot "vocabulary_id": #> [1] "ATC" #> #> Slot "concept_class_id": #> [1] "ATC 5th" #> #> Slot "standard_concept": #> [1] "C" #> #> Slot "concept_code": #> [1] "C09AA03" #> #> Slot "valid_start_date": #> [1] "1970-01-01" #> #> Slot "valid_end_date": #> [1] "2099-12-31" #> #> Slot "invalid_reason": #> [1] NA #>
lookup_atc_class_ingredients(atc_concept_obj = lisinopril_class)
#>
#> ── QA Concept Object ───────────────────────────────────────────────────────────
#> Concept belongs to ATC Vocabulary
#> Concept is an OMOP vocabulary class
#>
#> ── Render & Query ──────────────────────────────────────────────────────────────
#> [2021-05-26 16:00:53] Connected to 'athena' #> [2021-05-26 16:00:53] Postgres connection to 'athena' closed
#> # A tibble: 1 x 10 #> concept_id concept_name domain_id vocabulary_id concept_class_id #> <int> <chr> <chr> <chr> <chr> #> 1 1308216 lisinopril Drug RxNorm Ingredient #> # … with 5 more variables: standard_concept <chr>, concept_code <chr>, #> # valid_start_date <date>, valid_end_date <date>, invalid_reason <chr>