Bold or italicize the variable labels or the variable levels of a table.
bold_labels() and italicize_labels() format the rows with
row_type == "label"; bold_levels() and italicize_levels() format
every other row of the first visible column, which includes the level and
missing-value rows of a tbl_summary table.
Usage
bold_labels(x)
bold_levels(x)
italicize_labels(x)
italicize_levels(x)
# S3 method for class 'ltsummary'
bold_labels(x)
# S3 method for class 'ltsummary'
bold_levels(x)
# S3 method for class 'ltsummary'
italicize_labels(x)
# S3 method for class 'ltsummary'
italicize_levels(x)See also
bold_p() for p-values, modify_bold() and modify_italic()
for arbitrary cells.
Other modify and format:
add_variable_group_header(),
bold_p(),
modify_abbreviation(),
modify_caption(),
modify_footnote_header(),
modify_header(),
modify_source_note(),
remove_row_type(),
separate_p_footnotes(),
sort_p()
Examples
# Example 1 ----------------------------------
trial |>
tbl_summary(include = c(trt, age, response)) |>
bold_labels() |>
italicize_levels()
# Example 2 ----------------------------------
# formatting combines
trial |>
tbl_summary(by = trt, include = grade) |>
bold_labels() |>
italicize_labels() |>
bold_levels()