[R] Really supress output from Sweave

Achim Zeileis Achim.Zeileis at wu-wien.ac.at
Wed Nov 23 17:32:41 CET 2005


On Wed, 23 Nov 2005, Fredrik Karlsson wrote:

> Hi,
>
> I am using Sweave for chapters in my thesis that contain results.
> In the beginning of each chapter, I use this to load libraries I need.

You want results=hide in your options for this chunk.
hth,
Z

> <<init,echo=FALSE,quiet=TRUE>>=
> library(gplots)
> library(Hmisc)
> library(e1071)
>
> @
>
>
> What I want is, of course, to supress messages written by this code,
> but what I get in the end is X-init.tex with this the contents below.
> How do I really supress it?
>
> /Fredrik
>
> Type library(help='Hmisc'), ?Overview, or ?Hmisc.Overview')
> to see overall documentation.
>
> NOTE:Hmisc no longer redefines [.factor to drop unused levels when
> subsetting.  To get the old behavior of Hmisc type dropUnusedLevels().
>
> Attaching package: 'Hmisc'
>
>
>         The following object(s) are masked from package:gdata :
>
>          reorder.factor
>
>
>         The following object(s) are masked from package:car :
>
>          recode
>
>
>         The following object(s) are masked from package:stats :
>
>          ecdf
> \end{Soutput}
> \begin{Soutput}
> Loading required package: class
>
> Attaching package: 'e1071'
>
>
>         The following object(s) are masked from package:Hmisc :
>
>          impute
>
>
>         The following object(s) are masked from package:gtools :
>
>          permutations
>
>
>         The following object(s) are masked from package:foreign :
>
>          read.octave
> \end{Soutput}
> \begin{Soutput}
> Attaching package: 'xtable'
>
>
>         The following object(s) are masked _by_ .GlobalEnv :
>
>          digits
>
>
>         The following object(s) are masked from package:Hmisc :
>
>          label label<-
> \end{Soutput}
> \end{Schunk}
>
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
>




More information about the R-help mailing list