Message-ID: <20040103230547.GA5500@mail2.sas.upenn.edu>
Date: 2004-01-03T23:05:47Z
From: Jonathan Baron
Subject: Exception handling
In-Reply-To: <001101c3d24d$1adb99e0$daca73c8@timy>
On 01/03/04 19:58, Pablo Yabo wrote:
>Hi,
>I want to know if it's possible to prevent that a stop call stops my
>program.
>I want to call a function that can fail calling a stop. But in that case I
>want to keep the control and do something else, not stop the program and
>print a message.
Perhaps something like:
if (CONDITION) {stop("ERROR MESSAGE")} else {DO SOMETHING ELSE}
or just
if (CONDITION) {stop("ERROR MESSAGE")}
and the do something else comes later.
Jon
--
Jonathan Baron, Professor of Psychology, University of Pennsylvania
Home page: http://www.sas.upenn.edu/~baron
R page: http://finzi.psych.upenn.edu/