Re: [R] warning messages

From: Gabor Grothendieck <>
Date: Mon 26 Jun 2006 - 01:06:23 EST

Try this:

f <- function() {

	cat("c to continue, anything else to quit: ")
	x <- readline()
	if (x != "c") stop("User forced exit")
	# rest of function



On 6/25/06, Matthew Bridgman <> wrote:
> I want to put warning messages into some of my functions to remind
> myself to change the output file names each time I run them. Is there a
> way to do this that will allow me to respond to the warning message
> (i.e. "continue function" or "cancel")?
> Thanks,
> Matt
> ______________________________________________
> mailing list
> PLEASE do read the posting guide!
> mailing list PLEASE do read the posting guide! Received on Mon Jun 26 01:09:35 2006

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Mon 26 Jun 2006 - 02:13:12 EST.

Mailing list information is available at Please read the posting guide before posting to the list.