A list of stopping conditions can be passed to the cmaes
function. Instead of hardconding the stopping criteria into the main function they exist as stand-alone functions for maximal flexibility and extendability.
makeStoppingCondition(name, message, stop.fun, code = name, control = list())
Arguments
name: [character(1)]
Name of the stopping condition.
message: [character(1)]
Message returned if the stopping conditions is active.
stop.fun: [function]
Function which expects an environment envir as its only argument and returns a single logical value.
code: [character(1)]
Internal code, i.e., short name used to potentially trigger restarts. Default is name.