我想知道是否可以将 R markdown
结果直接嵌入句子中,如下所示:
让我们想象这是我的 R markdown
文件
---
title: "R markdown is great"
author: "Giacomo"
date: "15 Oct 2015"
output: pdf_document
---
The mean number of `disp` is
```{r}
mean(mtcars$disp)
```
and the ...
所以我明白
是否有可能产生类似的东西
最佳答案
此 Rmarkdown 引用指南展示了如何做到这一点:https://www.rstudio.com/wp-content/uploads/2015/03/rmarkdown-reference.pdf
disp
的平均数为 `rmean(disp)`
。
关于Rmarkdown - 嵌入句子中,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33146630/