-
Notifications
You must be signed in to change notification settings - Fork 330
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
Multi-column table output prioritizes center of new page or top of new page in PDF #11684
Comments
Could you update your code to be fully reproducible? |
It turns out this was not a Quarto problem but a potential problem with the
The conclusion I came to is that The problem described in the above threads occurred when I was using the Quarto documentation syntax for tables. Adding the following ---
title: "Title"
author: "Author"
format:
pdf: default
gfm: default
date: "2024-12-16"
sansfont: "Times New Roman"
mainfont: "Times New Roman"
# fix table floats
header-includes:
- \usepackage{float}
- \floatplacement{table}{H}
---
```{r}
#| label: imports
#| include: false
library(tidyverse)
library(lubridate)
library(readxl)
library(knitr)
```
<!-- Other R and Markdown chunks -->
```{r}
#| label: tbl-label
#| echo: false
#| tbl-cap: "Caption"
#| tbl-subcap:
#| - "Subcaption 1"
#| - "Subcaption 2"
#| layout-ncol: 2
knitr::kable(tbl1)
knitr::kable(tbl2)
``` Should I still edit my original post @mcanouil ? |
First So, yes, please provide a small reproducible example. It would be appreciated. |
@mcanouil The |
That is exactly what I needed. After cross-referencing with other issues and discussions, I see that it's mentioned in the future milestones already as well. Thank you! |
I am going to reopen because The first issue I am aware of using |
Never mind, let's close this one. |
Bug description
I am trying to use the YAML chunk options mentioned in Table Computations to create a two-column output with separate tables. I am observing one of the following two cases:
kable
print, where a PDF page break occurs in the middle of the Markdown chunk, then thekable
print interrupts the chunk at the top of the following page before continuing the Markdown preceding it sequentially.kable
print is "skipped" sequentially so that it can be printed at the center of the following page.Steps to reproduce
Case 1:
Case 2:
Expected behavior
PDF Export Case 1:
Table 1 should print after the 3rd "lorem ipsum" paragraph.
PDF Export Case 2:
Table 1 should print after the 4th "lorem ipsum" paragraph.
Actual behavior
PDF Export Case 1:
Table 1 prints at the top of Page 2, in the middle of the 5th "lorem ipsum" paragraph.
PDF Export Case 2:
Table 1 prints after the 5th "lorem ipsum" paragraph and at the center of Page 2.
Your environment
R version 4.4.1 (2024-06-14)
IDE/Platform: Sublime Text 3
OS: MacOS Sequoia 15.1.1
Quarto check output
The text was updated successfully, but these errors were encountered: