[R] logging messages

Prof Brian Ripley ripley at stats.ox.ac.uk
Tue Nov 16 09:05:38 CET 2004


On Mon, 15 Nov 2004, Faber Fedor wrote:

> Hi all,
>
> I'm trying to learn R from an non-statistician's POV. I've got a
> statistician who uses R, but I'm the schmuck who has to integrate his
> R functions into an automated process.

Defining a POV (undefined, as is `schmuck') as `not something' is really 
non-communication.  Please do read the R posting guide and its references, 
and try to formulate questions in standard (and polite) English.  Also, 
check the correct list to use as described in that posting guide -- R-help 
is not intended for questions involving programming concepts (like 
`syslog', which needs explanation even there).

> One of the things I would really like is the ability to log messages
> to file, specifically using syslog on a Linux box.  (I also want to
> write messages to STDOUT based on a command-line flag, but I figure
> that can't be too hard to figure out. If it is too hard to figure out,
> you'll be seeing another message from me shortly. :-)

It's not clear what you mean by this.  If you mean send warnings and 
messages to stdout (what is `STDOUT'?) then `why?'  You deal with this the 
same way as any other Linux application that uses stderr for warning/error 
messages.

To `tee' output, see ?sink, or indeed `man tee'.

R is principally an interactive program used for exploration.  You haven't 
told us what you are trying to do, and you may be better off embedding R 
in some other front end to give you more control.

-- 
Brian D. Ripley,                  ripley at stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595




More information about the R-help mailing list