Often, when I am building tables for reports, I want there to be an empty row in between variables. Currently, I can manually add an empty row with dplyr::add_row(). Here is an example from the Sun Study report:
# Add a blank line in between each classroom
table_ss_application <- table_ss_application %>%
add_row(Classroom = "", `Sunscreen Application Outcome` = "",
Baseline = "", Intervention = "",
Randomization = "", Maintenance = "", .after = 5
) %>%
add_row(Classroom = "", `Sunscreen Application Outcome` = "",
Baseline = "", Intervention = "",
Randomization = "", Maintenance = "", .after = 11
) %>%
add_row(Classroom = "", `Sunscreen Application Outcome` = "",
Baseline = "", Intervention = "",
Randomization = "", Maintenance = "", .after = 17
)
However, that is long and clunky, and you have to list every variable by name. I want to come up with something more generic I can use to quickly add empty rows.
Would be even better if it were possible to do this directly in flextable rather than in data frames.
Often, when I am building tables for reports, I want there to be an empty row in between variables. Currently, I can manually add an empty row with dplyr::add_row(). Here is an example from the Sun Study report:
However, that is long and clunky, and you have to list every variable by name. I want to come up with something more generic I can use to quickly add empty rows.
Would be even better if it were possible to do this directly in flextable rather than in data frames.