RweaveLatex {tools} | R Documentation |
R/LaTeX Driver for Sweave
Description
A driver for Sweave
that translates R code chunks in
LaTeX files.
Usage
RweaveLatex()
RweaveLatexSetup(file, syntax, output=NULL, quiet=FALSE, debug=FALSE,
echo=TRUE, eval = TRUE, split=FALSE, stylepath=TRUE,
pdf=TRUE, eps=TRUE)
Arguments
file |
Name of Sweave source file. |
syntax |
An object of class |
output |
Name of output file, default is to remove extension
‘.nw’, ‘.Rnw’ or ‘.Snw’ and to add extension
‘.tex’. Any
directory names in |
quiet |
If |
debug |
If |
stylepath |
If |
echo |
set default for option |
eval |
set default for option |
split |
set default for option |
pdf |
set default for option |
eps |
set default for option |
Supported Options
RweaveLatex supports the following options for code chunks (the values in parentheses show the default values):
- echo:
logical (
TRUE
). Include S code in the output file?- eval:
logical (
TRUE
). IfFALSE
, the code chunk is not evaluated, and hence no text or graphical output produced. \itemresults:character string (verbatim
). Ifverbatim
, the output of S commands is included in the verbatim-like Soutput environment. Iftex
, the output is taken to be already proper latex markup and included as is. Ifhide
then all output is completely suppressed (but the code executed during the weave). \itemprint:logical (FALSE
). IfTRUE
, each expression in the code chunk is wrapped into aprint()
statement before evaluation, such that the values of all expressions become visible. \itemterm:logical (TRUE
). IfTRUE
, visibility of values emulates an interactive R session: values of assignments are not printed, values of single objects are printed. IfFALSE
, output comes only from explicitprint
orcat
statements. \itemsplit:logical (FALSE
). IfTRUE
, text output is written to seperate files for each code chunk. \itemstrip.white:logical (TRUE
). IfTRUE
, blank lines at the beginning and end of output are removed. \itemprefix:logical (TRUE
). IfTRUE
generated filenames of figures and output have a common prefix. \itemprefix.string:a character string, default is the name of the ‘.Snw’ source file. \iteminclude:logical (TRUE
), indicating whether input statements for text output and includegraphics statements for figures should be auto-generated. Useinclude=FALSE
if the output should appear in a different place than the code chunk (by placing the input line manually). \itemfig:logical (FALSE
), indicating whether the code chunk produces graphical output. Note that only one figure per code chunk can be processed this way. \itemeps:logical (TRUE
), indicating whether EPS figures shall be generated. Ignored iffig=FALSE
. \itempdf:logical (TRUE
), indicating whether PDF figures shall be generated. Ignored iffig=FALSE
. \itemwidth:numeric (6), width of figures in inch. \itemheight:numeric (6), height of figures in inch.
Friedrich Leisch
Friedrich Leisch: Sweave User Manual, 2002
http://www.ci.tuwien.ac.at/~leisch/Sweave
Sweave
, Rtangle
utilities