dmt01_1.Rd
For each variable, summary statistics are by default based on the number of patients in the corresponding n
row.
dmt01_1(
adam_db,
armvar = .study$planarm,
summaryvars = c("AAGE", "AGEGR1", "SEX", "ETHNIC", "RACE"),
summaryvars_lbls = var_labels_for(adam_db$adsl, summaryvars),
lbl_overall = .study$lbl_overall,
prune_0 = TRUE,
deco = std_deco("DMT01"),
.study = list(planarm = "ARM", lbl_overall = "All Patients")
)
dmt01_1_lyt(
armvar = .study$planarm,
summaryvars = .study$summary_demo,
summaryvars_lbls = .study$summary_demo_lbl,
lbl_overall = .study$lbl_overall,
deco = std_deco("DMT01"),
.study = list(planarm = "ARM", summary_demo = c("AAGE", "AGEGR1", "SEX", "ETHNIC",
"RACE"), summary_demo_lbl = c("Age (yr)", "Pooled Age Group 1 (yr)", "SEX", "ETHNIC",
"RACE"), lbl_overall = "All Patients")
)
dmt01_1_pre(adam_db)
(dm
) object containing the ADaM datasets
(character
) variable used for column splitting
(vector of strings
) variables summarized in demographic table.
(vector of strings
) labels corresponding to the analyzed variables.
(character
) label used for overall column, if set to NULL
the overall column is omitted
(logical
) remove 0 count rows
(character
) decoration with title
, subtitles
and main_footer
content
(list
) with default values for the arguments of the function
Information from ADSUB are generally included into ADSL before analysis.
Default demographic and characteristics table
If not specified otherwise, numbers represent absolute numbers of patients and fraction of N
Remove zero-count rows
Split columns by arm (planned or actual / code or description)
Include a total column by default
dmt01_1_lyt
: dmt01_1
Layout
dmt01_1_pre
: dmt01_1
Preprocessing
library(dm)
db <- syn_test_data() %>%
dmt01_1_pre()
dmt01_1(db, summaryvars = c("AGE", "RACE", "SEX"))
#> Demographics and Baseline Characteristics: {Specify Population}
#> Protocol: {{protocol}}
#>
#> ———————————————————————————————————————————————————————————————————————————————————————————————————————
#> A: Drug X B: Placebo C: Combination All Patients
#> (N=134) (N=134) (N=132) (N=400)
#> ———————————————————————————————————————————————————————————————————————————————————————————————————————
#> Age
#> n 134 134 132 400
#> Mean (SD) 33.8 (6.6) 35.4 (7.9) 35.4 (7.7) 34.9 (7.4)
#> Median 33.0 35.0 35.0 34.0
#> Min - Max 21.0 - 50.0 21.0 - 62.0 20.0 - 69.0 20.0 - 69.0
#> Race
#> n 134 134 132 400
#> ASIAN 68 (50.7%) 67 (50%) 73 (55.3%) 208 (52%)
#> BLACK OR AFRICAN AMERICAN 31 (23.1%) 28 (20.9%) 32 (24.2%) 91 (22.8%)
#> WHITE 27 (20.1%) 26 (19.4%) 21 (15.9%) 74 (18.5%)
#> AMERICAN INDIAN OR ALASKA NATIVE 8 (6%) 11 (8.2%) 6 (4.5%) 25 (6.2%)
#> MULTIPLE 0 1 (0.7%) 0 1 (0.2%)
#> NATIVE HAWAIIAN OR OTHER PACIFIC ISLANDER 0 1 (0.7%) 0 1 (0.2%)
#> Sex
#> n 134 134 132 400
#> Female 79 (59%) 82 (61.2%) 70 (53%) 231 (57.8%)
#> Male 55 (41%) 52 (38.8%) 62 (47%) 169 (42.2%)
dmt01_1(db, summaryvars = c("AGE", "RACE", "SEX"), lbl_overall = NULL)
#> Demographics and Baseline Characteristics: {Specify Population}
#> Protocol: {{protocol}}
#>
#> ————————————————————————————————————————————————————————————————————————————————————————
#> A: Drug X B: Placebo C: Combination
#> (N=134) (N=134) (N=132)
#> ————————————————————————————————————————————————————————————————————————————————————————
#> Age
#> n 134 134 132
#> Mean (SD) 33.8 (6.6) 35.4 (7.9) 35.4 (7.7)
#> Median 33.0 35.0 35.0
#> Min - Max 21.0 - 50.0 21.0 - 62.0 20.0 - 69.0
#> Race
#> n 134 134 132
#> ASIAN 68 (50.7%) 67 (50%) 73 (55.3%)
#> BLACK OR AFRICAN AMERICAN 31 (23.1%) 28 (20.9%) 32 (24.2%)
#> WHITE 27 (20.1%) 26 (19.4%) 21 (15.9%)
#> AMERICAN INDIAN OR ALASKA NATIVE 8 (6%) 11 (8.2%) 6 (4.5%)
#> MULTIPLE 0 1 (0.7%) 0
#> NATIVE HAWAIIAN OR OTHER PACIFIC ISLANDER 0 1 (0.7%) 0
#> Sex
#> n 134 134 132
#> Female 79 (59%) 82 (61.2%) 70 (53%)
#> Male 55 (41%) 52 (38.8%) 62 (47%)
dmt01_1(db,
summaryvars = c("AGE", "RACE", "SEX"),
summaryvars_lbls = c("Age (yr)", "Race", "Sex")
)
#> Demographics and Baseline Characteristics: {Specify Population}
#> Protocol: {{protocol}}
#>
#> ———————————————————————————————————————————————————————————————————————————————————————————————————————
#> A: Drug X B: Placebo C: Combination All Patients
#> (N=134) (N=134) (N=132) (N=400)
#> ———————————————————————————————————————————————————————————————————————————————————————————————————————
#> Age (yr)
#> n 134 134 132 400
#> Mean (SD) 33.8 (6.6) 35.4 (7.9) 35.4 (7.7) 34.9 (7.4)
#> Median 33.0 35.0 35.0 34.0
#> Min - Max 21.0 - 50.0 21.0 - 62.0 20.0 - 69.0 20.0 - 69.0
#> Race
#> n 134 134 132 400
#> ASIAN 68 (50.7%) 67 (50%) 73 (55.3%) 208 (52%)
#> BLACK OR AFRICAN AMERICAN 31 (23.1%) 28 (20.9%) 32 (24.2%) 91 (22.8%)
#> WHITE 27 (20.1%) 26 (19.4%) 21 (15.9%) 74 (18.5%)
#> AMERICAN INDIAN OR ALASKA NATIVE 8 (6%) 11 (8.2%) 6 (4.5%) 25 (6.2%)
#> MULTIPLE 0 1 (0.7%) 0 1 (0.2%)
#> NATIVE HAWAIIAN OR OTHER PACIFIC ISLANDER 0 1 (0.7%) 0 1 (0.2%)
#> Sex
#> n 134 134 132 400
#> Female 79 (59%) 82 (61.2%) 70 (53%) 231 (57.8%)
#> Male 55 (41%) 52 (38.8%) 62 (47%) 169 (42.2%)
dmt01_1_lyt(armvar = "ACTARM")
#> A Pre-data Table Layout
#>
#> Column-Split Structure:
#> ACTARM (lvls)
#> (all obs)
#>
#> Row-Split Structure:
#> AAGE:AGEGR1:SEX:ETHNIC:RACE (** multivar analysis **)
#>
syn_test_data() %>%
dmt01_1_pre()
#> ── Metadata ────────────────────────────────────────────────────────────────────
#> Tables: `adsl`, `adae`, `adaette`, `adcm`, `addv`, … (15 total)
#> Columns: 846
#> Primary keys: 2
#> Foreign keys: 1