commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gilles Sadowski <gil...@harfang.homelinux.org>
Subject Re: [math] RegressionModelSpecificationException
Date Thu, 21 Jul 2011 18:18:09 GMT
On Thu, Jul 21, 2011 at 10:48:40AM -0700, Phil Steitz wrote:
> I propose that we add this to replace the generic math IAE that we
> throw in various places, e.g. in AbstractMLR#newSampleData,
> 
> throw MathRuntimeException.createIllegalArgumentException(
>                     LocalizedFormats.INVALID_REGRESSION_ARRAY,
> data.length, nobs, nvars);

This way of generating exceptions is deprecated (as are classes
"o.a.c.math.MathException" and "o.a.c.math.MathRuntimeException").

Please make it
---CUT---
import org.apache.commons.math.exception.MathIllegalArgumentException;
 // ...
 throw new MathIllegalArgumentException(LocalizedFormats.INVALID_REGRESSION_ARRAY,
                                        data.length, nobs, nvars);
---CUT---

However, if many of the new classes are going to contain similar statements,
maybe that a new "RegressionException" is warranted.
 
> [...]

Thanks,
Gilles

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Mime
View raw message