This function (and its similarly named counterpart
is an R function that provides a similar interface as the executable
xsltproc. It is intended for use by an R script that
implements the Sxsltproc command on Windows, Linux and OS X.
Note that the name of the XSL file preceeds the name of the XML file
in the arguments. This is to mimic the call sequence of
It is the reverse of
a character vector of command line arguments. This currently supports –param name value and –stringparam name value as three separate consecutive arguments. It also supports –output and -o to specify the output file name. If neither is specified, the output is sent to the console unless –noout is specified in which case no output is generated.
The value returned by outputting the result or the document itself if there is no output.
Currently, we output the XML declaration
regardless of whether it is desired or not, e.g. a text file being created,
or if there is an XSL declaration that suppresses it.
Duncan Temple Lang
xsltproc at http://www.xmlsoft.org
1 2 3 4 5 6 7 8 9 10 11
## Not run: # In the shell Sxsltproc tests/simple.xsl tests/simple.xml Sxsltproc --param foo "'123'" tests/simple.xsl tests/simple.xml Sxsltproc --stringparam foo "123" tests/simple.xsl tests/simple.xml # In R Sxsltproc(c("tests/simple.xsl", "tests/simple.xml")) Sxsltproc(c("--param", "foo", "'123'", "tests/simple.xsl", "tests/simple.xml")) ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.