如何在 r markdown 中指定自定义纸张尺寸

MSD*_*MSD 4 latex r knitr r-markdown

我正在使用 R Markdown 制作具有特定高度和长度测量值的小册子。有没有办法指定 R Markdown 以 5.5"x8.5" 尺寸生成文章。

我在这里看到有关制作 A4 尺寸 pdf 的问题,但这无济于事,因为我的衡量标准非常具体。

use*_*330 8

使用 YAML 中的几何选项(它成为 LaTeX 中几何包的选项)。例如:

---
title: "Title"
author: "Me"
geometry: paperheight=8.5in,paperwidth=5.5in,margin=1in
output:
    pdf_document
---

```{r setup, include=FALSE}
knitr::opts_chunk$set(echo = TRUE)
```

## R Markdown

This is an R Markdown document. Markdown is a simple formatting
syntax for authoring HTML, PDF, and MS Word documents. For more
details on using R Markdown see <http://rmarkdown.rstudio.com>.
Run Code Online (Sandbox Code Playgroud)