RweaveAsciidoc: A driver to parse asciidoc noweb files with Sweave tool This...

View source: R/RweaveAscii.r

RweaveAsciidocR Documentation

A driver to parse asciidoc noweb files with Sweave tool This driver parses asciidoc files containing R code and replace pieces of code with their output.

Description

A driver to parse asciidoc noweb files with Sweave tool This driver parses asciidoc files containing R code and replace pieces of code with their output.

weaverAsciidocSetup

weaverAsciidoc

Usage

RweaveAsciidoc()

weaverAsciiSetup(
  file,
  syntax,
  output = NULL,
  quiet = FALSE,
  debug = FALSE,
  extension = "txt",
  backend = "asciidoc",
  openSchunk = "----",
  closeSchunk = "\n----\n",
  openSinput = "",
  closeSinput = "",
  openSoutput = "\n",
  closeSoutput = "",
  indent = "",
  openInclude = "include::",
  closeInclude = ".txt[]",
  openFig = "image::",
  closeFig = "[]",
  use.cache = TRUE,
  ...
)

weaverAsciidoc()

Arguments

use.cache

use.cache

Value

None value is returned. From a .Rnw noweb file, the corresponding .txt is produced (as eventuals files for graphs).

Note

In order to work properly, noweb codes have to be located at the beginning of a line (no indentation).

Compare with RweaveLatex driver, RweaveAsciidoc provides one new option : format to choose the format of figure that will be inserted in the final document.

In addition, cache option from weaver package is also available with weaverAsciidoc driver.

A wrapper for Sweave can be used, named Asciidoc.

Author(s)

David Hajage dhajage@gmail.com

See Also

Sweave, Asciidoc

Examples

  ## Not run: 
Asciidoc(system.file("examples/Asciidoc-test-1.nw",package="ascii"))
Asciidoc(system.file("examples/Asciidoc-test-1.nw",package="ascii"),weaverAsciidoc())
system("asciidoc Asciidoc-test-1.txt")
  
## End(Not run)


ascii documentation built on May 29, 2024, 6:10 a.m.

Related to RweaveAsciidoc in ascii...