knit2pdf {knitr} | R Documentation |
Knit the input Rnw or Rrst document, and compile to PDF using texi2pdf
or rst2pdf
.
knit2pdf(input, output = NULL, compiler = NULL, envir = parent.frame(), quiet = FALSE, encoding = getOption("encoding"), ...)
input |
path of the input file |
output |
path of the output file for |
compiler |
a character string which gives the LaTeX program used to
compile the tex document to PDF (by default it uses the default setting of
|
envir |
the environment in which the code chunks are to be evaluated
(for example, |
quiet |
whether to suppress the progress bar and messages |
encoding |
the encoding of the input file; see |
... |
The filename of the PDF file.
The output
argument specifies the output filename to be passed
to the PDF compiler (e.g. a tex document) instead of the PDF filename.
Ramnath Vaidyanathan, Alex Zvoleff and Yihui Xie
#' compile with xelatex ## knit2pdf(..., compiler = 'xelatex') #' compile a reST file with rst2pdf ## knit2pdf(..., compiler = 'rst2pdf')