pharmaverse/cardinal

[New Table]: Table 35

Closed this issue · 1 comments

Table Layout & Design

table-35

Please refer to page 76 (83 of PDF file) of the FDA guideline document for more details.

Table Description

Table 35. Patients With Adverse Events1 by System Organ Class, Safety Population, Pooled Analysis (or Trial X)²

Analysis Datasets

adsl
adae

When using data from the scda package, please use datasets with archive_name set to "rcd_2022_10_13".

Analysis Filters

Safety population: SAFFL == "Y"

Additional Information

Maybe try to use {pharmaverseadam} for dummy dataframes.

Developer To Dos

  • Table Function: Create R/fda-table_XX.R file with your table-generating function.
    • Roxygen Documentation: title, @details, document all parameters, @return, @examples, @export.
  • Tests: Create tests/testthat/test-table_XX.R file with tests for the table function and then run these tests.
  • Quarto Template: Create quarto/table-templates/template-table_XX.qmd file your table template.
  • Screenshot: Add table screenshot as table_XX.png to the quarto/assets/images/screenshots folder.
  • _quarto.yml: Add template to the "Template Library" section of the _quarto.yml file.
  • Template Index: Run quarto/assets/generate-template_index.R script to update the template index.
  • NEWS: Update NEWS.md.

I'm wondering if prune_0 should stay in the function. For now, the table display only the SOCs that are present in the database. In this case, prune_0 should not be needed, right?
Still, SOCs are fixed by the MedDRA and the complete list can be found here on table 3-1 (p11-12): https://admin.meddra.org/sites/default/files/guidance/file/intguide_26_1_English.pdf
Do we need to get the full list and apply it in the function? In this case, the user could use prune_0 to show (or not) all the SOCs.

Also, I searched on both {scda} and {pharmaverseadam} and I think I did not found the variable to arrange the SOC list in the correct order. For now, it's arranged alphabetically.

What do you think?