Reputation: 33
I'm using rmarkdown in rstudio and want to knit to pdf. This works well, except for when I use kable. I'm using the following yaml and it used to work in the past, but now I had to reinstall R, Rstudio and MacTex and now it doesn't work anymore.
---
title: "example"
output:
pdf_document:
df_print: kable
latex_engine: xelatex
---
```{r}
cars
```
The error message I get is:
output file: example.knit.md
! LaTeX Error: Environment kable-table undefined.
Error: LaTeX failed to compile example.tex. See https://yihui.org/tinytex/r/#debugging for debugging tips. See Study-1.log for more info.
Does anyone know how to solve this?
Upvotes: 3
Views: 2896
Reputation: 30104
This is a bug of rmarkdown (against higher versions of Pandoc), which I just fixed on Github. Please try:
remotes::install_github('rstudio/rmarkdown')
Upvotes: 3