2017-02-23 1 views
6

quand je tricote HTML en studio R, je reçois ceci:pandoc conversion de documents a échoué avec l'erreur 2

"C:/Users/Susan/ANACON~1/Scripts/pandoc" +RTS -K512m -RTS lesson3_student.utf8.md --to html --from markdown+autolink_bare_uris+ascii_identifiers+tex_math_single_backslash --output lesson3_student.html --smart --email-obfuscation none --self-contained --standalone --section-divs --template "C:\Users\Susan\Documents\R\win-library\3.3\rmarkdown\rmd\h\default.html" --no-highlight --variable highlightjs=1 --variable "theme:bootstrap" --include-in-header "C:\Users\Susan\AppData\Local\Temp\RtmpaUaaRx\rmarkdown-str3cf45da21737.html" --mathjax --variable "mathjax-url: https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML " output file: lesson3_student.knit.md

unrecognized option `--smart' Try pandoc.exe --help for more information. Error: pandoc document conversion failed with error 2 In addition: Warning message: running command '"C:/Users/Susan/ANACON~1/Scripts/pandoc" +RTS -K512m -RTS lesson3_student.utf8.md --to html --from markdown+autolink_bare_uris+ascii_identifiers+tex_math_single_backslash --output lesson3_student.html --smart --email-obfuscation none --self-contained --standalone --section-divs --template "C:\Users\Susan\Documents\R\win-library\3.3\rmarkdown\rmd\h\default.html" --no-highlight --variable highlightjs=1 --variable "theme:bootstrap" --include-in-header "C:\Users\Susan\AppData\Local\Temp\RtmpaUaaRx\rmarkdown-str3cf45da21737.html" --mathjax --variable "mathjax-url: https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML "' had status 2 Execution halted

Quelqu'un peut-il me donner une idée de ce qui a mal tourné et comment y remédier?

Merci

+0

Hm, pourriez-vous inclure le YAML pour votre fichier Rmd? –

+0

Je suppose que la version de 'pandoc' dans votre cas vient sans le support du drapeau' --smart'. Probablement, vous avez une installation Anaconda ou quelque chose de similaire, et cela fournit une version de 'pandoc' qui ne supporte pas ce drapeau? –

Répondre

15

Aujourd'hui, j'ai eu le même problème. je pouvais réparer en définir l'option intelligente false, comme décrit here:

output: 
    html_document: 
     smart: false 

Il semble que « --smart » ne prend plus en charge la nouvelle version de pandoc 1.19.2.1. Même cela devrait, discusion on the RStudio forum

+0

Cela fonctionne, très bien! –