[R] putting output from print() into a string?

David Firth david.firth at nuffield.oxford.ac.uk
Sun Nov 12 12:12:03 CET 2000

Is there some neat way of storing the printed representation of an 
object as a character string?  I can see how it could be done via 
disk using sink() and then scan(), but that's ugly.

Something like Lisp-Stat's "with-output-to-string" macro perhaps?

David Firth                        Phone +44 1865 278544
Nuffield College                   Fax   +44 1865 278621
Oxford OX1 1NF                     Secretary +44 1865 278612
United Kingdom                     Email david.firth at nuffield.oxford.ac.uk

r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch

More information about the R-help mailing list