Hi. > > I am working on limited dependent variable regressions. I am testing part of > a logit regression routine. As part of the estimation technique I am need to > do some nonlinear optimization. Using the > NonLinearConjugateGradientOptimizer, I submit my problem, but get the > following exception: > > org.apache.commons.math.exception.MathIllegalStateException: unable to > bracket optimum in line search > at > org.apache.commons.math.optimization.general.NonLinearConjugateGradientOptimizer.findUpperBound(NonLinearConjugateGradientOptimizer.java:258) > at > org.apache.commons.math.optimization.general.NonLinearConjugateGradientOptimizer.doOptimize(NonLinearConjugateGradientOptimizer.java:185) > at > org.apache.commons.math.optimization.direct.BaseAbstractScalarOptimizer.optimize(BaseAbstractScalarOptimizer.java:130) > at > org.apache.commons.math.optimization.general.AbstractScalarDifferentiableOptimizer.optimize(AbstractScalarDifferentiableOptimizer.java:79) > > > I have checked that the gradients are consistent with the object function. I > have verified that numerical (finite differences) gradient and my analytical > one agree. Since the problem is logit, there is no issue of negative > numbers. > > What could I be doing wrong? The solver is called using Polak-Ribiere > updating scheme.
I'd suggest to modify your copy of "NonLinearConjugateGradientOptimizer", adding "println" statements[1] so that you can see why "findUpperBound" fails. [It seems that the "step" might be too large in your case.] Regards, Gilles [1] No logging unfortunately... :-{ --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@commons.apache.org For additional commands, e-mail: dev-h...@commons.apache.org