Name | Modified | Size | Downloads / Week |
---|---|---|---|
Parent folder | |||
gtsummary 2.3.0 source code.tar.gz | 2025-07-03 | 19.3 MB | |
gtsummary 2.3.0 source code.zip | 2025-07-03 | 19.6 MB | |
README.md | 2025-07-03 | 4.0 kB | |
Totals: 3 Items | 39.0 MB | 2 |
New Features and Functions
-
Added
tbl_split_by_rows()
andtbl_split_by_columns()
to split tables horizontally (row-wise) and vertically (column-wise). (#2216) -
Users are now allows to specify/override the denominator by passing an integer or a data frame to the
tbl_summary(percent)
argument. (#2239) -
Added the
tbl_merge(tbl_ids)
andtbl_stack(tbl_ids)
arguments that allows used to label the gtsummary input tables. This is particularly helpful when callinggather_ard()
, which will return a named list of ARDs where the names are the assigned tbl IDs. (#2224) -
Adding new function
add_difference_row()
. The function is similar toadd_difference()
, except that differences are placed on the rows below the summary statistics. (#2138) -
The
style_*()
andlabel_style_*()
functions have gained thena
argument allowing users to specify howNA
values are returned. -
The
tbl_stack(attr_order)
argument has been added that allows users to specify the order in which the individual attributes take precedent when they are stacked. For example, to use the headers from the second table, specifyattr_order=2
. (#2202) -
The
tbl_regression()
function now takes advantage of a new feature in {broom.helpers} to support multicomponent models, such as, multinomial models and mixed-effects models. Reviewbroom.helpers::tidy_group_by()
for details. (#1540)
Other Updates
-
Added an article on
modify_*()
functions. (#2209) -
Added theme elements
tbl_hierarchical_count-fn:addnl-fn-to-run
andtbl_hierarchical_count-fn:addnl-fn-to-run
. (#2262) -
Added the
"add_overall.tbl_summary-arg:col_label"
theme element to control the default value ofadd_overall.tbl_summary(col_label)
. (#2246) -
Variable labels are now retained with
tbl_summary(sort=~'frequency')
. (#2260) -
Functions
sort_hierarchical()
andfilter_hierarchical()
are now S3 generics. -
The
add_overall()
function no longer returns an error when an unstratified table is passed. Rather, a message is printed and the unaltered table is returned.
Lifecycle Updates
- Updated the function name of
modify_column_indent()
to the more accurately namedmodify_indent()
as the function operates on cells rather than columns.
Bug Fixes
-
Fix in
tbl_svysummary()
when there are missing values in theby
column. -
Fixed bug in
tbl_hierarchical()
causing the overall row label to be incorrectly used as a variable label. -
Fixed bug in
sort_hierarchical()
causing some rows to be dropped when sorting unstratified tables. (#2237) -
Fixed bug in
filter_hierarchical()
causing an error for unstratified tables. -
Fix in
gather_ard()
fortbl_regression()
andtbl_uvregression()
. Previously, only the ARD for the primary regression model(s) would be returned, and now all ARDs are returned including those from subsequent calls toadd_*()
functions. (#2208) -
Fix in
tbl_merge(merge_vars)
argument when a table contained a"row_type"
column and the tables were not merged by this variable (which is included in the default). (#2205) -
Fix in
add_overall()
where not all table styling were copied from the overall table to the newly merged table. This did not affect any native gtsummary tables, but did appear in an extension package. -
Fix in experimental function
modify_post_fmt_fun()
when tables including this call, did not specify therows
argument, and were later stacked. Theenquo
environment associated with therows
argument was empty when the argument is not specified, and the empty environment caused an issue with evaluation if the table was later stacked. -
Fix in
tbl_svysummary(missing='ifany')
when the weighted number of missing observations was <= 0.5. Previously, these counts were coerced to integer and rounded to zero, and therefore, did not appear in the table. (#2229) -
Fix in
gather_ard()
fortbl_strata_nested_stack()
tables, where the function returned an empty list. (#2223)