RMD转换为PDF

RMD转换为PDF,pdf,r-markdown,Pdf,R Markdown,我正在尝试将RMD转换为PDF,但不断出现此错误 output file: hw1.knit.md /Volumes/RStudio-0.99.893/RStudio.app/Contents/MacOS/pandoc/pandoc +RTS -K512m -RTS hw1.utf8.md --to latex --from markdown+autolink_bare_uris+ascii_identifiers+tex_math_single_backslash --output hw1.

我正在尝试将RMD转换为PDF,但不断出现此错误

output file: hw1.knit.md

/Volumes/RStudio-0.99.893/RStudio.app/Contents/MacOS/pandoc/pandoc +RTS -K512m -RTS hw1.utf8.md --to latex --from markdown+autolink_bare_uris+ascii_identifiers+tex_math_single_backslash --output hw1.tex --template /Library/Frameworks/R.framework/Versions/3.2/Resources/library/rmarkdown/rmd/latex/default-1.15.2.tex --highlight-style tango --latex-engine /Library/TeX/texbin/xelatex --variable graphics=yes --variable 'geometry:margin=1in' 
/Volumes/RStudio-0.99.893/RStudio.app/Contents/MacOS/pandoc/pandoc +RTS -K512m -RTS hw1.utf8.md --to latex --from markdown+autolink_bare_uris+ascii_identifiers+tex_math_single_backslash --output hw1.pdf --template /Library/Frameworks/R.framework/Versions/3.2/Resources/library/rmarkdown/rmd/latex/default-1.15.2.tex --highlight-style tango --latex-engine /Library/TeX/texbin/xelatex --variable graphics=yes --variable 'geometry:margin=1in' 
! LaTeX Error: Command \end{enumerate} invalid in math mode.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
...                                              

l.206 \end{enumerate}

pandoc: Error producing PDF from TeX source
Error: pandoc document conversion failed with error 43
输出文件:hw1.knit.md
/Volumes/RStudio-0.99.893/RStudio.app/Contents/MacOS/pandoc/pandoc+RTS-K512m-RTS hw1.utf8.md--到latex--从标记+自动链接\u裸\u URI+ascii\u标识符+tex\u数学\u单反斜杠--输出hw1.tex--模板/库/框架/R.framework/Versions/3.2/Resources/Library/rmarkdown/rmd/latex/default-1.15.2.tex--突出显示风格探戈--latex引擎/Library/TeX/texbin/Xeletex--变量图形=是--变量“几何体:边距=1in”
/Volumes/RStudio-0.99.893/RStudio.app/Contents/MacOS/pandoc/pandoc+RTS-K512m-RTS hw1.utf8.md--到latex--从标记+自动链接\u裸\u URI+ascii\u标识符+tex\u数学\u单反斜杠--输出hw1.pdf--模板/库/框架/R.framework/Versions/3.2/Resources/Library/rmarkdown/rmd/latex/default-1.15.2.tex--突出显示风格探戈--latex引擎/Library/TeX/texbin/Xeletex--变量图形=是--变量“几何体:边距=1in”
! LaTeX错误:命令\end{enumerate}在数学模式下无效。
有关说明,请参阅LaTeX手册或LaTeX配套手册。
键入H以获得即时帮助。
...                                              
l、 206\结束{枚举}
pandoc:从TeX源生成PDF时出错
错误:pandoc文档转换失败,错误为43
如果格式完全转换成html,但我需要一个PDF。 我有TeX,并尝试了我在这里看到的各种修复,但没有任何效果

Enumerate应该是

1。部分
2.编号列表

*联合国-
*有序列表


你能发布你的.Rmd的那部分吗?

你可以使用
keep_tex:true
来保存中间tex文件,并查看第206行中到底发生了什么……这是一个很好的建议,允许我解决类似的问题。就我而言,我写的是
$\equival50%$
,而不是
$\equival50\%$
(在
%
前面缺少反斜杠)。