title: convert tex to pdf using texi2pdf in Rstudio
body: <p>I got error msg when converting tex to pdf using texi2pdf function in Rstudio. </p>
  
  <pre><code>tools::texi2pdf('test.tex')
  </code></pre>
  
  <p>and the error msg I got:</p>
  
  <pre><code>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)
  </code></pre>
  
  <p>I am running windows10, R version 3.5.1 , RStudio 1.1.463 and CTeX_2.9.2.164.</p>
  
  <p>Anyone could help me with this problem? Thanks.</p>