Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- writeLines('
- <<echo=FALSE, results="asis">>=
- writeLines("Hello World!")
- @
- ', "foo.Rnw")
- knitr::knit("foo.Rnw", quiet = TRUE)
- writeLines(readLines("foo.tex"))
- ##
- ## Hello World!
- ##
- knitr::render_sweave()
- knitr::knit("foo.Rnw", quiet = TRUE)
- writeLines(readLines("foo.tex"))
- ##
- ## begin{Soutput}
- ## Hello World!
- ## end{Soutput}
- ##
- writeLines('
- <<echo=FALSE, results=tex>>=
- writeLines("Hello World!")
- @
- ', "foo.Rnw")
- utils::Sweave("foo.Rnw", quiet = TRUE)
- writeLines(readLines("foo.tex"))
- ##
- ## Hello World!
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement