resu...">

How to apply R output as a LaTex partition?

Suppose I have an R fragment in an x.rnw file such as

<<section1, echo=F>>=
> x <- "A_B_C"
> result <- paste0("\\section {",gsub("_","\\\\_",x),"}")
> cat(result)
\section {A\_B\_C}
@

How to make output \section {A\_B\_C}executable as \sectionduring sweave or knitr ?

+3
source share

All Articles