I need to print flextable output in a Rmarkdown file knitting to .docx format. Even if I include the chunk option 'ft.keepnext=T' the table is still split.
I could manually add a pagebreak before the code chunk, but I'd rather do this programmatically.
1 Like
I also had this question for awhile. I was just composing an email to David (the developer) himself, but then I got the ft.keepnext parameter to work. It has to be added in the setup (1st) chunk of the .RMD file. For example:
```{r setup, include=FALSE}
knitr::opts_chunk$set(echo = FALSE, ft.keepnext = F)
``'
After adding the parameter there, my flextables all seem to be no longer page-jumping.
Note: I'm setting it to FALSE, since I want the rows to not block-together.
1 Like