Look at the spin and stitch functions in the knitr package if you want to process an existing script into an output that mixes the code run with the output.
Look at the txtStart and related functions in the TeachingDemos package if you want the code and output saved in a file from a session where you are typing in commands. If in general you want text, code, and output mixed, learn the knitr and/or rmarkdown packages for how to write a file that can be processed into a report. Also consider learning about RStudio notebook documents where you can have the output mixed into the "script" file. On Tue, Apr 24, 2018 at 3:23 AM, P. Roberto Bakker <robertobak...@gmail.com> wrote: > Hi everybody, > > How can I get text from RScript (e.g. syntax, reminder) into the result > text. > Sink() does not do that - I only read the results and therefore I have to > 'guess' which syntax was used where - reminders I wrote are lost. > > Bw and thank you in advance, > > Roberto > > [[alternative HTML version deleted]] > > ______________________________________________ > R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. -- Gregory (Greg) L. Snow Ph.D. 538...@gmail.com ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.