# \donttest{
library(DrugUtilisation)
library(dplyr)
#>
#> Attaching package: ‘dplyr’
#> The following objects are masked from ‘package:stats’:
#>
#> filter, lag
#> The following objects are masked from ‘package:base’:
#>
#> intersect, setdiff, setequal, union
cdm <- mockDrugUtilisation()
cdm[["drug_exposure"]] |>
filter(drug_concept_id == 2905077) |>
addDailyDose(ingredientConceptId = 1125315)
#> Warning: `addDailyDose()` was deprecated in DrugUtilisation 0.7.0.
#> # Source: table<og_018_1723211495> [4 x 9]
#> # Database: DuckDB v1.0.0 [unknown@Linux 6.5.0-1025-azure:R 4.4.1/:memory:]
#> drug_exposure_id person_id drug_concept_id drug_exposure_start_date
#> <int> <int> <dbl> <date>
#> 1 2 1 2905077 2009-05-02
#> 2 11 5 2905077 2016-06-05
#> 3 23 10 2905077 1994-09-11
#> 4 24 10 2905077 1992-05-27
#> # ℹ 5 more variables: drug_exposure_end_date <date>,
#> # drug_type_concept_id <dbl>, quantity <dbl>, daily_dose <dbl>, unit <chr>
# }