无法从Windows 10 PC中的Rstudio编写Rmardown的pdf

时间:2017-10-27 14:54:47

标签: latex rstudio knitr

我在最新的R和Rstudio版本中创建了一个新的Rmd文件,并安装了完整版的MiKTeX。在我的Windows 10机器上。

当我尝试编织时,我收到以下错误

! LaTeX Error: File `fancyvrb.sty' not found.

Type X to quit or <RETURN> to proceed,
or enter new name. (Default extension: sty)

Enter file name: 
! Emergency stop.
<read *> 

l.34 \newcommand

pandoc.exe: Error producing PDF
Error: pandoc document conversion failed with error 43
Además: Warning message:
comando ejecutado '"C:/Program Files/RStudio/bin/pandoc/pandoc" +RTS -K512m -RTS pdfprueba.utf8.md --to latex --from markdown+autolink_bare_uris+ascii_identifiers+tex_math_single_backslash --output pdfprueba.pdf --template "C:\Users\karin\Documents\R\win-library\3.3\rmarkdown\rmd\latex\default-1.17.0.2.tex" --highlight-style tango --latex-engine pdflatex --variable graphics=yes --variable "geometry:margin=1in"' tiene estatus 43 

Ejecucióninterrumpida

我怀疑可能是因为我没有MiKTeX中的软件包fancyvrb,所以我遵循了these指令,但我仍然遇到同样的错误。

1 个答案:

答案 0 :(得分:1)

使用

尝试相同的操作
Miktex package manager (admin)

在&gt;下存储库检查您的包存储库是否是最新的。 在名称框中,键入包的名称 然后过滤 然后添加你的包 adding fancyvrb to miktex

测试您的软件包是否以dos CMD类型安装 kpsewhich fancyvrb.sty。你应该能够看到你的包裹的路径。

Microsoft Windows [version 10.0.15063]
(c) 2017 Microsoft Corporation. Tous droits réservés.
C:\>kpsewhich fancyvrb.sty
C:/Users/me/AppData/Roaming/MiKTeX/2.9/tex/latex/fancyvrb/fancyvrb.sty