inst/examples/knitr-input.Rnw
raw| 1 | \documentclass{article} |
| 2 | |
| 3 | \begin{document} |
| 4 | |
| 5 | <<test-main>>= |
| 6 | options(width = 60) |
| 7 | summary(iris) |
| 8 | @ |
| 9 | |
| 10 | Let's see how to work with child documents in knitr. Below we input |
| 11 | the file \textsf{knitr-input-child.Rnw}: |
| 12 | |
| 13 | <<child-demo, child='knitr-input-child.Rnw'>>= |
| 14 | @ |
| 15 | % Or alternatively, use knit_child('knitr-input-child.Rnw') in \Sexpr |
| 16 | |
| 17 | Done! |
| 18 | |
| 19 | \end{document} |