-
Notifications
You must be signed in to change notification settings - Fork 130
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bug Report: spanner wrong in docx rendering #2109
Comments
Thanks for the post @raffaem ! If you don't include the ---
title: "Untitled"
format: docx
---
## Quarto
```{r}
library(gtsummary)
packageVersion("gtsummary")
list(
tbl_regression(lm(mpg ~ wt, data = mtcars)),
tbl_regression(lm(mpg ~ wt+gear, data = mtcars))
) |>
tbl_merge(tab_spanner=c("Model 1", "Model2"))
``` |
So how can I get the gt code to reproduce that table, so I can report it upstream? |
You can use list(
tbl_regression(lm(mpg ~ wt, data = mtcars)),
tbl_regression(lm(mpg ~ wt+gear, data = mtcars))
) |>
tbl_merge(tab_spanner=c("Model 1", "Model2")) |>
as_gt(return_calls = TRUE) |
Consider the following Quarto MWE:
This is how is rendered in PDF (good):
This is how it is rendered in docx.
The spanner is wrong, as the first header covers only one column instead of 3:
The text was updated successfully, but these errors were encountered: