[R] Sweave and the "[" function

Friedrich Leisch Friedrich.Leisch at stat.uni-muenchen.de
Tue Sep 5 13:27:46 CEST 2006


>>>>> On Tue, 05 Sep 2006 20:56:33 +1000,
>>>>> Ross Darnell (RD) wrote:

  > Hi Vincent
  > This would seem logical but in this case doesn't work.
  > It doesn't seem to be a Sweave problem (feature) at all  but within R as 
  > Hadley stated.

Yes, Sweave parses & deparses the code in oreder to make full
expressions out of lines of text, i.e., to "know" where open
parentheses are closed etc. This is necessary in order to know where
to insert output when multiple lines are contained in one code chunk,
but unfortunately looses the original formatting as has correctly been
explained earlier in this thread.

Best,
Fritz

-- 
-----------------------------------------------------------------------
Prof. Dr. Friedrich Leisch 

Institut für Statistik                          Tel: (+49 89) 2180 3165
Ludwig-Maximilians-Universität                  Fax: (+49 89) 2180 5308
Ludwigstraße 33
D-80539 München                 http://www.stat.uni-muenchen.de/~leisch



More information about the R-help mailing list