On Wed, 12 May 2004, Vadim Ogranovich wrote: > > > > -----Original Message----- > > From: Prof Brian Ripley [mailto:[EMAIL PROTECTED] > > Sent: Tuesday, May 11, 2004 11:21 PM > > To: Vadim Ogranovich > > Cc: R-Help > > Subject: Re: [R] recover should send messages to stderr, not stdout > > > ... > > > > Note that some of us consider recover() to be designed for > > interactive-only use, and use something like > > Unfortunately, R help doesn't reflect the apparent diversity of > opinions. Regarding recover it says
Well, I got my suggestion from the work of the author of those words, on page 268 of the Green Book, so I don't think your `apparent' is based on careful reading. > The use of 'recover' largely supersedes 'dump.frames' as an error > option, unless you really want to wait to look at the error. If > 'recover' is called in non-interactive mode, it behaves like > 'dump.frames'. <...> > > > options(error=expression(if(interactive()) recover() else > > dump.calls())) > > This is useful. Thank you very much for the tip! > > > On Tue, 11 May 2004, Vadim Ogranovich wrote: > > > > > recover() sends all its messages, which I consider to be error > > > messages, to stdout. I think they more properly belong to stderr. > > > > > > This is an important difference for those of us who use R in batch > > > mode to generate ASCII files. > > > > Only to the subset who believe that recover() is a useful > > error option in > > non-interactive use. > > This subset is likely to include everyone who carefully reads the > documentation, see the above excerpt from a help page. Everyone who reads that carefully will realize that in batch use you do want (and need) to wait for the error. -- Brian D. Ripley, [EMAIL PROTECTED] 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 ______________________________________________ [EMAIL PROTECTED] mailing list https://www.stat.math.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
