optimbase.checkcostfun: Check Cost Function

Description Usage Arguments Details Value Author(s) See Also

Description

This function checks that the cost function is correctly specified in the optimization object, including that the elements of this used by the cost function are consistent.

Usage

1

Arguments

this

An optimization object

Details

Depending on the definition of nonlinear constraints (nbineqconst element > 0) and the use of derivatives (withderivatives element set to TRUE), this function makes several cost function calls with different index value (see vignette('optimbase',package='optimbase') for more details about index). If at least one call fails, the function stops the search algorithm.

Following every successful cost function call, optimbase.checkcostfun calls optimbase.checkshape to check the dimensions of the matrix returned by the cost function against some expectations.

Value

Return the optimization object or an error message if one check is not successful.

Author(s)

Author of Scilab optimbase module: Michael Baudin (INRIA - Digiteo)

Author of R adaptation: Sebastien Bihorel (sb.pmlab@gmail.com)

See Also

optimbase.checkshape



Search within the optimbase package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.