[R] RMySQL, Sweave and the annoying TRUE echo
Duncan Murdoch
murdoch at stats.uwo.ca
Fri Jan 29 12:35:12 CET 2010
Stefan Petersson wrote:
> Hi,
>
> A small (but annoying) problem with RMySQL library. When a connection is closed, it echoes 'TRUE' to the console. Like this:
>
> R> mysqlCloseConnection(con)
> [1] TRUE
>
> The real problem comes when I use RMySQL with Sweave, since the TRUE echo gets into my final Sweave document. Even when I explicitly state <<include=FALSE, echo=FALSE>>= in the header of the R code chunk.
>
include=FALSE stops graphs from being included. echo=FALSE stops the R
input from being echoed. You want results=hide to stop the results from
being shown.
So to make that call completely invisible, use
<<echo=FALSE, results=hide>>=
mysqlCloseConnection(con)
@
Duncan Murdoch
> Is there a way to suppress this TRUE echo?
>
> TIA
>
> / s
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>
More information about the R-help
mailing list