Let's say I have an Rmarkdown document. In that document, I create an data frame with two columns, and each of them is quite long. Also I have the "paged" output setting.
---
title: "Long Tables"
output:
html_document:
toc: true
toc_depth: 3
df_print: paged
---
```{r}
alphabet = paste(LETTERS, letters, collapse = "", sep = "")
data.frame(
a = rep(alphabet, 10),
b = rep(alphabet, 10)
)
When I knit this to HTML, it appears like this:
It is important that I can get both columns to fit on screen without the user having to click through to each column. Ideally there would be an rmarkdown setting to solve this. If not, is there a way to actually truncate the columns behind the scenes, but without actually showing the user the code that is doing the truncation? Because this will complicate the example that I am demonstrating in the document.