addRScript.bsdoc

0th

Percentile

Add R script into a bsdoc object

Add R script into a bsdoc object.

Usage
# S3 method for bsdoc
addRScript(doc, rscript, file, text, ...)
Arguments
doc

bsdoc object where expressions have to be added

file

R script file. Not used if text or rscript is provided.

text

character vector. The text to parse. Not used if file or rscript is provided.

rscript

an object of class RScript. Not used if file or text is provided.

...

further arguments, not used.

Details

You have to one of the following argument: file or text or rscript.

Value

an object of class bsdoc.

See Also

bsdoc, addRScript

Aliases
  • addRScript.bsdoc
Examples
# NOT RUN {
#START_TAG_TEST
doc.filename = "addRScript_bsdoc/example.html"

# set default font size to 11
options( "ReporteRs-fontsize" = 11 )

doc = bsdoc( )
doc = addRScript(doc, text = "x = rnorm(100)
plot(density( x ) )" )

# Write the object
writeDoc( doc, file = doc.filename )
#STOP_TAG_TEST
# }
Documentation reproduced from package ReporteRs, version 0.6.9, License: GPL-3

Community examples

Looks like there are no examples yet.