如何在R rmarkdown

时间:2015-10-09 11:06:40

标签: r r-markdown pandoc

我正在使用R rmarkdown包将.Rmd文件呈现给html输出。 正如我所理解的,此程序包正在使用pandoc.md文件转换为html。在我的CentOS计算机下,版本如下

CentOS Linux release 7.0.1406 (Core) 
NAME="CentOS Linux"
VERSION="7 (Core)"
ID="centos"
ID_LIKE="rhel fedora"
VERSION_ID="7"
PRETTY_NAME="CentOS Linux 7 (Core)"
ANSI_COLOR="0;31"
CPE_NAME="cpe:/o:centos:centos:7"
HOME_URL="https://www.centos.org/"
BUG_REPORT_URL="https://bugs.centos.org/"

CentOS Linux release 7.0.1406 (Core) 
CentOS Linux release 7.0.1406 (Core) 
cpe:/o:centos:centos:7

我有pandoc版本

-bash-4.2$ pandoc --version
pandoc 1.12.4.2

但是当我运行rmarkdown::render()函数时,我收到了这样的错误

Error: pandoc version 1.12.3 or higher is required and was not found.
Execution halted

我认为R正在使用它的本地pandoc,看起来它比我的全局pandoc更旧。有谁知道如何在pandoc中指定全局R rmarkdown的全局路径?

1 个答案:

答案 0 :(得分:0)

正如@langusta建议的那样,我使用了这个答案并且它起作用了:Fiddler

相关问题