/** * {@inheritDoc} * * @throws MathIllegalStateException if {@code optData} does not contain an * instance of {@link MaxEval} or {@link SearchInterval}. */ @Override public UnivariatePointValuePair optimize(OptimizationData... optData) { // Store arguments in order to pass them to the internal optimizer. optimData = optData; // Set up base class and perform computations. return super.optimize(optData); }
return lineOptimizer.optimize(new MaxEval(Integer.MAX_VALUE), new UnivariateObjectiveFunction(f), goal,
optimData[searchIntervalIndex] = new SearchInterval(min, max, s); optima[i] = optimizer.optimize(optimData); } catch (RuntimeException mue) { lastException = mue;
/** * {@inheritDoc} * * @throws MathIllegalStateException if {@code optData} does not contain an * instance of {@link MaxEval} or {@link SearchInterval}. */ @Override public UnivariatePointValuePair optimize(OptimizationData... optData) { // Store arguments in order to pass them to the internal optimizer. optimData = optData; // Set up base class and perform computations. return super.optimize(optData); }
/** * {@inheritDoc} * * @throws MathIllegalStateException if {@code optData} does not contain an * instance of {@link MaxEval} or {@link SearchInterval}. */ @Override public UnivariatePointValuePair optimize(OptimizationData... optData) { // Store arguments in order to pass them to the internal optimizer. optimData = optData; // Set up base class and perform computations. return super.optimize(optData); }
/** * Maximum likelihood estimate (MLE) of examinee ability. * * @param thetaMin smallest possible ability estimate (lower bound on BrentOptimizer) * @param thetaMax largest possible ability estimate (upper bound on BrentOptimizer) * @return MLE of examinee ability */ public double maximumLikelihoodEstimate(double thetaMin, double thetaMax, int maxIter, double tolerance){ method = EstimationMethod.ML; UnivariateOptimizer optimizer = new BrentOptimizer(tolerance, 1e-14); UnivariatePointValuePair pair = optimizer.optimize(new MaxEval(maxIter), new UnivariateObjectiveFunction(this), GoalType.MAXIMIZE, new SearchInterval(thetaMin, thetaMax)); estimatedTheta = pair.getPoint(); return estimatedTheta; }
/** * Maximum a Posteriori (MAP) estimate of examinee ability using a normal prior * quadrature. * * @param mean mean of normal prior quadrature * @param sd standard deviation of prior quadrature * @param thetaMin smallest possible ability estimate (lower bound on BrentOptimizer) * @param thetaMax largest possible ability estimate (upper bound on BrentOptimizer) * @return MAP estimate of examinee ability */ public double mapEstimate(double mean, double sd, double thetaMin, double thetaMax, int maxIter, double tolerance){ mapPrior = new NormalDistribution(mean, sd); method = EstimationMethod.MAP; UnivariateOptimizer optimizer = new BrentOptimizer(tolerance, 1e-14); UnivariatePointValuePair pair = optimizer.optimize(new MaxEval(maxIter), new UnivariateObjectiveFunction(this), GoalType.MAXIMIZE, new SearchInterval(thetaMin, thetaMax)); estimatedTheta = pair.getPoint(); return estimatedTheta; }
return lineOptimizer.optimize(new MaxEval(Integer.MAX_VALUE), new UnivariateObjectiveFunction(f), goal,
return lineOptimizer.optimize(new MaxEval(Integer.MAX_VALUE), new UnivariateObjectiveFunction(f), goal,
optimData[searchIntervalIndex] = new SearchInterval(min, max, s); optima[i] = optimizer.optimize(optimData); } catch (RuntimeException mue) { lastException = mue;
optimData[searchIntervalIndex] = new SearchInterval(min, max, s); optima[i] = optimizer.optimize(optimData); } catch (RuntimeException mue) { lastException = mue;