Check analytic gradient and hessian against their numerical approximation
Usage
checkGH(object, tol)
Arguments
object
an object of class mlt as returned by mlt
tol
tolerance, passed to all.equal.
Details
Computes the gradient and hessian analytically and numerically and compares the
two. Warnings are suppressed for the numerical approximations as they are
not aware of model constraints which might get violated.