.list2tb {gtsummary} | R Documentation |
Convert Named List to Table Body
Description
Many arguments in 'gtsummary' accept named lists. This function converts
a named list to the .$table_body
format expected in scope_table_body()
Usage
.list2tb(x, colname = caller_arg(x))
Arguments
x |
named list |
colname |
string of column name to assign. Default is |
Value
.$table_body
data frame
Examples
type <- list(age = "continuous", response = "dichotomous")
gtsummary:::.list2tb(type, "var_type")
[Package gtsummary version 2.2.0 Index]