【发布时间】:2021-03-09 18:02:30
【问题描述】:
我使用 RMarkdown 创建了 pdf 格式的讲义,但它有很多子标题。因此,我想创建两个不同的目录:第一个深度为 1 的目录,然后分别为 4 深度的目录。
添加 toc_depth: 1 和 toc_depth: 4 无效。
我的 YAML 标头:
---
title: "Lecture Notes"
author: "x"
output:
pdf_document:
highlight: tango
toc: true
toc_depth: 4 #depth table of contents
number_sections: true
documentclass: article
classoption: a4paper
fontsize: 12pt
geometry: "right=1cm, left=1cm, top=1cm, bottom=3cm"
---
【问题讨论】:
标签: r-markdown tableofcontents