You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The create_single_dose_dataset() function is correctly deriving dates for ASTDT and AENDT but not for ASTDTM and AENDTM. The function should split diary card data (where each record covers a range of dates) into one line per date. It does this correctly for ASTDT and AENDT, but it keeps the earliest recorded date for ASTDTM and AENDTM. Please see screenshot attached for example data.
Session Information
R version 4.0.3 (2020-10-10)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Red Hat Enterprise Linux
Matrix products: default
BLAS/LAPACK: /usr/lib64/libopenblas-r0.2.20.so
locale:
[1] LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C LC_TIME=en_US.UTF-8 LC_COLLATE=en_US.UTF-8 LC_MONETARY=en_US.UTF-8
[6] LC_MESSAGES=en_US.UTF-8 LC_PAPER=en_US.UTF-8 LC_NAME=C LC_ADDRESS=C LC_TELEPHONE=C
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] purrr_0.3.4 rice_2.0 lubridate_1.7.9 dplyr_1.0.2 admiraltest_0.2.0 admiral_0.7.0
loaded via a namespace (and not attached):
[1] Rcpp_1.0.8 rstudioapi_0.11 magrittr_2.0.3 getPass_0.2-2 hms_0.5.3 tidyselect_1.1.0 R6_2.5.0 rlang_1.0.2 stringr_1.4.0
[10] httr_1.4.2 tools_4.0.3 cli_3.3.0 ellipsis_0.3.2 digest_0.6.27 assertthat_0.2.1 tibble_3.0.4 lifecycle_0.2.0 crayon_1.3.4
[19] readr_1.4.0 tidyr_1.1.2 vctrs_0.4.1 curl_4.3 memoise_1.1.0 glue_1.6.2 haven_2.3.1 stringi_1.5.3 compiler_4.0.3
[28] pillar_1.4.6 forcats_0.5.0 generics_0.1.0 jsonlite_1.7.1 pkgconfig_2.0.3
Thanks a lot for reporting this @morrishj! I've removed the example you provided which contain calls to accessing Roche data for a little reproducible example that shows the same problem.
@pharmaverse/admiral (especially @amsmith214 & @bundfussr) I feel like not only the --DT variables but also --DTM variables should be populated with calculated values. I'm also not sure how I feel about the original SDTM variables just being retained from the original record. Maybe set to NA instead?
We could change start_date and end_date to start_date_prefix and end_date_prefix respectively. Date and Datetime variables with the prefix are populated if they exist in the input dataset. Imputation flag variables with the prefix are set to NA.
Regarding retaining variables from the input dataset we have two options:
We retain all variables and provide a set_values_to parameter, which could be used to set variables to NA which should not be retained.
We retain no variables and provide a keep_source_vars parameter, which could be used to specify the variables which should be retained.
The set_values_to parameter could also be used to set variables like PARAMCD in the case that the single doses should be added to the ADEX dataset as separate parameter.
What happened?
The create_single_dose_dataset() function is correctly deriving dates for ASTDT and AENDT but not for ASTDTM and AENDTM. The function should split diary card data (where each record covers a range of dates) into one line per date. It does this correctly for ASTDT and AENDT, but it keeps the earliest recorded date for ASTDTM and AENDTM. Please see screenshot attached for example data.
Session Information
Reproducible Example
The text was updated successfully, but these errors were encountered: