在Rstudio中使用texi2pdf将tex转换为pdf

时间:2018-11-15 09:05:58

标签: r latex rstudio knitr

在Rstudio中使用texi2pdf函数将tex转换为pdf时出现错误msg。

tools::texi2pdf('test.tex')

和我得到的错误消息:

Error in system(paste(shQuote(texi2dvi), if (quiet) "--quiet" else "",  : 
  (converted from warning) running command     '"C:\CTEX\MiKTeX\miktex\bin\texi2dvi.exe" --quiet --pdf "test.tex" --max-iterations=20 -I "C:/Program Files/R/R-3.5.1/share/texmf/tex/latex" -I "C:/Program Files/R/R-3.5.1/share/texmf/bibtex/bst"' had status 1
 1: tools::texi2pdf("test.tex")
 2: texi2dvi(file = file, pdf = TRUE, clean = clean, quiet = quiet, texi2dvi = texi2dvi, texinputs = texinputs, index = index)
 3: system(paste(shQuote(texi2dvi), if (quiet) "--quiet" else "", if (pdf) "--pdf" else "", shQuote(file), extra), intern = TRUE, ignore.stderr = TRUE)
 4: .signalSimpleWarning("running command '\"C:\\CTEX\\MiKTeX\\miktex\\bin\\texi2dvi.exe\" --quiet --pdf \"test.tex\" --max-iterations=20 -I \"C:/Program Files/R/R-3.5.1/share/texmf/tex/latex\" -I \"C:/Program Files/R/R
 5: withRestarts({
.Internal(.signalCondition(simpleWarning(msg, call), msg, call))
.Internal(.dfltWarn(msg, call))
}, muffleWarning = function() NULL)
 6: withOneRestart(expr, restarts[[1]])
 7: doWithOneRestart(return(expr), restart)

我正在运行Windows10,R版本3.5.1,RStudio 1.1.463和CTeX_2.9.2.164。

有人可以帮助我解决这个问题吗?谢谢。

0 个答案:

没有答案