3.5 Custom Digits Argument

The digits and digits.cat arguments can be changed to a custom numerical value. The default digits is 1, the default digits.cat is 0

rm_compactsum(data=pembrolizumab, xvars=c('age','pdl1','change_ctdna_group'), grp = 'sex', use_mean = c("pdl1"), digits = 2, digits.cat = 1, effSize = T, show.tests = T)
Full Sample (n=94) Female (n=58) Male (n=36) p-value Effect Size (95% CI) Missing pTest effStat
age 59.12 (49.54-68.71) 56.64 (45.80-67.83) 61.16 (51.99-69.44) 0.30 0.11 (-0.08, 0.21) 0 Wilcoxon Rank Sum Wilcoxon r
pdl1 13.90 (29.24) 15.02 (30.55) 12.06 (27.26) 0.63 0.10 (-0.40, 0.20) 1 t-test Cohen’s d
change ctdna group - Increase from baseline 40 (54.8%) 21 (52.5%) 19 (57.6%) 0.84 0.02 (-0.18, 0.05) 21 ChiSq Cramer’s V

To specify custom digit arguments for different numerical variables, change the digits argument. Unspecified variables will use the default value.

rm_compactsum(data=pembrolizumab, xvars=c('age','pdl1','l_size'), grp = 'sex', digits = c("age" = 3, "l_size" = 2), effSize = T, show.tests = T)
Full Sample (n=94) Female (n=58) Male (n=36) p-value Effect Size (95% CI) Missing pTest effStat
age 59.121 (49.542-68.708) 56.643 (45.800-67.834) 61.164 (51.992-69.438) 0.30 0.11 (-0.09, 0.21) 0 Wilcoxon Rank Sum Wilcoxon r
pdl1 0.0 (0.0-10.0) 0.5 (0.0-13.8) 0.0 (0.0-4.5) 0.76 0.03 (-0.17, 0.06) 1 Wilcoxon Rank Sum Wilcoxon r
l size 73.50 (49.25-108.75) 68.00 (44.25-97.75) 93.00 (65.50-121.00) 0.066 0.19 (0.00, 0.36) 0 Wilcoxon Rank Sum Wilcoxon r