我运行这段代码,但是它没有编号我的身材
## Including Plots
You can also embed plots, for example (Figure \@ref(fig:titanic))
```{r titanic, fig.cap='(ref:titanic)'}
plot(pressure)
```
我的文件开始如下:
---
title: "Untitled"
output:
html_document:
fig_caption: true
---
答案 0 :(得分:2)
此问题已经here回答。答案列出了解决问题的几种方法,将文档设置为bookdown::html_document2
似乎是最简单的解决方案。即修改您的YAML标头:
---
title: "Untitled"
output: bookdown::html_document2
---