From kirill.mueller at ivt.baug.ethz.ch  Fri Jan  3 01:53:43 2014
From: kirill.mueller at ivt.baug.ethz.ch (=?ISO-8859-1?Q?Kirill_M=FCller?=)
Date: Fri, 3 Jan 2014 01:53:43 +0100
Subject: [Rd] Sweave trims console output in "tex" mode
In-Reply-To: <52C60835.8060605@gmail.com>
References: <52C5FEAF.5020708@ivt.baug.ethz.ch> <52C60835.8060605@gmail.com>
Message-ID: <52C60A17.1040208@ivt.baug.ethz.ch>

On 01/03/2014 01:45 AM, Duncan Murdoch wrote:
> You are running with the strip.white option set to TRUE.  That strips 
> blank lines at then beginning and end of each output piece.  Just set 
> strip.white=FALSE.
Thanks, the code below works perfectly. I have also found the 
documentation in ?RweaveLatex .

I'm not sure if the default setting is sensible for "results=tex", 
though. Has this changed in the recent past?


-Kirill


\documentclass{article}
\begin{document}
<<inline,echo=FALSE,results=tex,strip.white=FALSE>>=
cat("a\n")
cat("b\n \n")
cat("c\nd")
@
\end{document}



[Rd] Sweave trims console output in "tex" mode
=?ISO-8859-1?Q?Kirill_M=FCller?=