Skip to content

Exporting Commands and Results

4 messages · Jeff Reichman, John Kane, Bert Gunter +1 more

#
R-Users

 

I know sink("filename") will export my results to a file but how do I export
both commands and results in R?

 

Jeff
#
Perhaps knitr (http://yihui.name/knitr/)? 

John Kane
Kingston ON Canada
____________________________________________________________
FREE 3D EARTH SCREENSAVER - Watch the Earth right on your desktop!
#
?savehistory

may also be relevant, depending on what you wish to do and how hard
you want to work.

Cheers,
Bert


Bert Gunter

"The trouble with having an open mind is that people keep coming along
and sticking things into it."
-- Opus (aka Berkeley Breathed in his "Bloom County" comic strip )
On Fri, Mar 18, 2016 at 3:00 PM, Jeff Reichman <reichmanj at sbcglobal.net> wrote:
#
You may want to try sink(filename, split=TRUE). If you have particularly
lengthy commands that you wish to save, you can run your syntax file using
source(filename, echo=TRUE, max.deparse.length=Inf) to keep R from
truncating the commands.
On Mar 19, 2016 10:59 AM, "Bert Gunter" <bgunter.4567 at gmail.com> wrote: