From b2ab3ce632b4ffb478ab41726523fbacd3aac8e8 Mon Sep 17 00:00:00 2001 From: jimrothstein Date: Thu, 10 Oct 2024 14:42:49 -0700 Subject: [PATCH] Remove functions src_ae_dthcaus_source() and src_ds_dthcaus_source() --- NEWS.md | 2 ++ inst/templates/ad_adsl.R | 18 +----------------- 2 files changed, 3 insertions(+), 17 deletions(-) diff --git a/NEWS.md b/NEWS.md index 91fb0405c..e3f53080a 100644 --- a/NEWS.md +++ b/NEWS.md @@ -9,6 +9,8 @@ - Replace use of `data("sdtm")` with `sdtm <- pharmaverse::sdtm` in templates and vignettes. (#2498) +- Remove src_ae_dthcaus_source() and src_ds_dthcaus_source(); replaced by derive_vars_extreme_event() 2517 and #XXXX) + ## Updates of Existing Functions ## Breaking Changes diff --git a/inst/templates/ad_adsl.R b/inst/templates/ad_adsl.R index 3abd7c357..42026c0a7 100644 --- a/inst/templates/ad_adsl.R +++ b/inst/templates/ad_adsl.R @@ -95,24 +95,8 @@ ex_ext <- ex %>% # Source objects ---- -# Death cause sources -src_ae <- dthcaus_source( - dataset_name = "ae", - filter = AEOUT == "FATAL", - date = convert_dtc_to_dtm(AESTDTC, highest_imputation = "M"), - mode = "first", - dthcaus = AEDECOD, - set_values_to = exprs(DTHDOM = "AE", DTHSEQ = AESEQ) -) +# Death cause sources, replaced by derive_vars_extreme_event() function -src_ds <- dthcaus_source( - dataset_name = "ds", - filter = DSDECOD == "DEATH" & grepl("DEATH DUE TO", DSTERM), - date = DSSTDT, - mode = "first", - dthcaus = DSTERM, - set_values_to = exprs(DTHDOM = "DS", DTHSEQ = DSSEQ) -) adsl <- dm %>% ## derive treatment variables (TRT01P, TRT01A) ----