Refinements of existing data check functions

Misc package updates

  • General updates for CRAN compliance, e.g. to DESCRIPTION file, Roxygen headers, etc.
  • Remove rm(list=ls()) from sdtmchecksmeta.R (#375)
  • Removed xls2list() function. If working with the results of run_all_checks() it’s recommended to output results to to .rds instead of parsing .xlsx files.

Refinements of existing data check functions

  • check_ae_aeacn_ds_disctx_covid add more header and unit tests, update header description that the check specifically looks for DSDECOD = ‘ADVERSE EVENT’ and include a note that a single DSDECOD = ‘ADVERSE EVENT’ will yield a pass but there may be multiple records in DS expected with this value #330
  • check_ae_aeacnoth add more header and unit tests for NA, minor update to return message #328
  • check_ae_aeout fix logic for the scenario when AEOUT is not populated but there is a non-missing AEDTHDTC, update return message (#318)
  • check_ae_aesdth_aedthdtc include AETERM for easier querying, added more header examples, updated return message. (#323). Update associated unit test to include AETERM (#324).
  • check_ae_aesdthdtc_aesdth bug fix for NA values not detected via original !(AE[["AESDTH"]]=="Y") logic leading to possible false negative result #247, include AETERM for easier querying, added more header examples, updated return message. (#322). Update associated unit test to include AETERM (#324).
  • check_dd_ae_aeout_aedthdtc fix logic for the scenario when AEOUT is not populated but there is a non-missing AEDTHDTC, update return message. This check overlaps with check_ae_aeout, but both will be retained for now to avoid breaking changes (#310)

Misc package updates

  • Update GitHub workflows (#316)

Metadata updates

  • Re-create sdtmchecksmeta.RData with MedDRA dictionary version 27.0 listed instead of 26.1 (#312)

Misc package updates

  • Unit test accompanying new CE check check_ce_missing_month() previously created by @rymarinelli added into tests/testthat subdirectory
  • Fix minor typo in README (#299)
  • Add cran-comments.md (#305)

Refinements of existing data check functions

New data check functions

  • check_ce_missing_month() - flags if CE has a suspicious date value with year and day known but month missing (#148), with thanks to @rymarinelli
  • check_ae_aeout_aeendtc_nonfatal() - flags AEs with inconsistent AE outcome (AEOUT) and AE resolution date (AEENDTC) for non-fatal AEs (based on AEOUT) (#113), with thanks to @J-Lox

Refinements of existing report utilities

Metadata updates

Misc package updates

  • Specify version >= 1.1.1 for dplyr version in DESCRIPTION
  • Replace “report_diff” with “Status” in globals.R to align with update in diff_reports() (#269)

New report utility functions

  • Added diff_reports() reporting function to utils.R to compare report objects generated from run_all_checks(), enabling identification of records newly flagged (#264), with thanks to @harriscw
  • Include “report_diff” in globals.R (#265)

Misc package updates

  • Automated security update in workflow (#268)

Refinements of existing data check functions

  • check_tu_rs_new_lesions updated to include overall response of PMD as an indicator of progressive disease. Visit info also added to check result. (#197)
  • check_ae_fatal updated to address bug that was causing warning. Logic was subsequently streamlined. (#215)
  • Checks that expect specific preferred terms identifying Covid-19 related AEs were updated to warn if that metadata was not provided. (#220 & #223)
  • --SEQ variables were removed from checks. (#246)

Metadata updates

Documentation updates

  • Roxygen2 header updated to include @family and @keyword for data check function categories OPHTH and COVID (#214) - applied to the following data checks:
    • COVID:
      • check_ae_aeacn_ds_disctx_covid.R
      • check_ae_aeacnoth_ds_stddisc_covid.R
      • check_dv_ae_aedecod_covid.R
      • check_dv_covid.R
    • OPHTH:
      • check_ae_aelat.R
      • check_cm_cmlat.R
      • check_cm_cmlat_prior_ocular.R
      • check_oe_bcva_1m_late_early_tot.R
      • check_oe_bcva_4m_late_early_tot.R
      • check_oe_bcva_4m_vs_1m_req.R
      • check_oe_bcva_tot_mismatch.R
      • check_oe_sc_lat_count_fingers.R
      • check_pr_prlat.R
      • check_sc_dm_eligcrit.R
      • check_sc_dm_seyeselc.R

Refinements of existing data check functions

New functions

  • Added xls2list() reporting function to create a list from spreadsheet tabs using the {openxlsx} package (#85)

Metadata updates

  • sdtmchecksmeta.RData saves as version=2 not version=3 for backwards compatibility with R < 3.5.0 when .RData loaded (#84)

Documentation updates

Misc package updates

  • Unit tests:
  • README:
    • Include badges on README:
    • README.Rmd added to render README.md (#172)
    • Add installation instructions from “https://pharmaverse.r-universe.dev” (devel branch, default) #195, #226
    • Specify recommended installation from main branch: devtools::install_github("pharmaverse/sdtmchecks", ref = "main")
  • Updated DESCRIPTION to specify:
    • New dependency: {testthat}
    • GitHub as Repository for sdtmchecks (#123)
    • Config/testthat/edition: 3 (#138)
  • Implemented {renv} for package dependency management, adding renvignore, renv.lock, renv subfolder and including updated .Rprofile (#111)
  • Package version 0.1.5.1 used prior to update to 0.1.6

New data check functions

Refinements of existing data check functions

Metadata updates

Misc updates

  • Clarification added to “Writing a New Check” Vignette if contributor does not have write access to the repo (#65)

Refinements of existing data check functions

New functions

  • New helper function utilities added to utils.R
    • create_R_script() can use sdtmchecksmeta.RData as input to programmatically generate an R script with function calls (#22)
    • report_to_xlsx() to generate the output results from selected data check functions as an .xlsx file including a tab for each check with potential discrepancies flagged and a summary page with conditional formatting to provide an overview of the results (#11)

New documentation

  • “Writing a New Check” published as Vignette (#5)

Misc updates

Misc updates

  • Removed package nickname from Description

Initial package deployment

  • Initial deployment of open-source sdtmchecks Pharmaverse package, based on code migrated from the internal Roche sdtmchecks package, which includes a variety of data checks and utility functions
  • All data check functions (check_xx....R) modified from Roche-specific version to include:
    • Updated roxygen2 headers with generalized examples
    • Pre-processing in the function call (preproc=identity,...) to allow company-specific pre-processing
  • Proprietary dataset call-ins removed
  • Metadata corresponding to all data check functions sdtmchecksmeta.RData added to the data subdirectory; Roche-specific acronyms removed from descriptive text
  • Utility functions added within separate roche_utils.R file for Roche-specific processing and to serve as a reference for implementation of company-specific pre-processing
  • globals.R added with explicit list to pass through utils::globalVariables()
  • Other general utility functions that are invoked within check_xx....R functions consolidated from separate .R scripts into utils.R:
  • README, LICENSE, DESCRIPTION, _pkgdown.yml, vignette files tailored to github.com/pharmaverse (#1)
  • Package logo added to man/figures
  • Package site created via pkgdown

New data check functions (post-migration)

  • check_ae_aeacnoth_ds_disctx() flags if an AE record indicates person discontinued from study but there is no corresponding DS record indicating study discontinuation (where DS.DSSCAT = "STUDY COMPLETION/EARLY DISCONTINUATION" and DS.DSDECOD != "COMPLETED") (#3)