On Wed, 19 Jan 2011, Giuseppe Vittucci wrote:

> I have to do a series of non linear least squares estimation within a
> loop and save the results in a matrix.
>
> The problem is that, when it happens that for some set of the parameters
> the NLS does not converge, instead of returning a null vector and going
> on with the loop, the program stops.
>
> Is there a way in gretl to tell the program not to stop? Something like
> the command "try" in R?

Yes, use "catch":

catch nls ...
 ...
end nls

Allin Cottrell

Reply via email to