偶尔,我在运行代码时遇到此错误,以便以pdf格式生成输出。我无法弄清楚为什么会这样。下面的代码有效但偶尔会出现这种错误。我必须关闭并重新打开RStudio来解决这个问题。
错误:
system(paste("pandoc -V geometry:margin=0.7in -o", Reports, "/report", ".pdf ",
"report", ".md" ,sep=""))
pandoc.exe: Error producing PDF from TeX source.
!pdfTeX error: pdflatex (file C:/Users/RM/Desktop/figure
/unnamed-chunk-4.png): reading image file failed
==> Fatal error occurred, no output PDF file produced!
Warning message:
running command 'pandoc -V geometry:margin=0.7in -o C:/Users/RM/Desktop/report.pdf
report.md' had status 43
编辑:
错误很难再现。所以我想知道是否有人能够仅仅从错误信息本身帮助。