Spin a child R script
This function is similar to knit_child()
but is used in R
scripts instead. When the main R script is not called via
spin()
, this function simply executes the child script via
sys.source()
, otherwise it calls spin()
to spin
the child script into a source document, and uses knit_child()
to compile it. You can call this function in R code, or using the syntax of
inline R expressions in spin()
(e.g.
{{knitr::spin_child('script.R')}}
).
spin_child(input, format)
input |
Filename of the input R script. |
format |
Passed to |
A character string of the knitted R script.
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.