I get extraneous output in my .tex file, which I cannot suppress with <> or sink (). It is noteworthy that unwanted strings are not enclosed in .. {Schunk} or similar.
This happens to me when I use either DEoptim or rjags, although this is probably not limited to these functions.
Example .Rnw file:
\documentclass[a4paper, 12]{article} begin{document} <<echo=FALSE>>= require(DEoptim) Rosenbrock <- function(x){
What I want to do The result that I would like is a tex file that will be created if the output was suppressed or, what is the same, if a piece of code has been removed from the .Rnw file:
\documentclass[a4paper, 12]{article} \usepackage{Sweave} \begin{document} \end{document}
What happens However, the resulting .tex file has a function exit:
\documentclass[a4paper, 12]{article} \usepackage{Sweave} \begin{document} Iteration: 1 bestvalit: 132.371451 bestmemit: -1.851683 4.543355 Iteration: 2 bestvalit: 8.620563 bestmemit: -1.854371 3.369908 ....few hundred lines of DEoptim output .... $member$storepop list() attr(,"class") [1] "DEoptim" \end{document}
Note that the output is not enclosed in \ begin {Schunk} \ end {Schunk}, so the $ signs mix LaTeX and it will not compile.
r sweave latex
David LeBauer
source share