-
Notifications
You must be signed in to change notification settings - Fork 218
Closed
Milestone
Description
Try using tab_style to cells_summary with row_group_order in my case will result in missing the style (or unformatted). It happens everytime. I am using latest version of gt from github.
library(dplyr)
library(tidyverse)
library(gt)
library(babynames)
numrows <- 6
numgroups <- 2
df <- tibble::tibble(
name = sample(babynames$name, numrows),
value = runif(numrows, 50000, 2000000),
group = sample(letters[1:numgroups], numrows, replace = TRUE)
)
gttbl <- df %>%
group_by(group) %>%
arrange(group) %>%
gt(rowname_col = "name") %>%
row_group_order(groups = c("b", "a")) %>%
summary_rows(groups = TRUE, columns = c(value), fns = list("sum")) %>%
tab_style(style = list(cell_text(style = "italic", weight="bold")),
locations = cells_summary())
gttblCreated on 2021-07-05 by the reprex package (v2.0.0)
Reactions are currently unavailable

