Finds optimal max and min value using an optimality criterion.
get_optimal_range(
max_range,
min_range,
resolution,
opt_crit,
choose_best,
minimize = TRUE
)
(numeric
of length 2) The min and max boundaries to the search space for
the optimal maximum value.
(numeric
of length 2) The min and max boundaries to the search space for
the optimal minimum value.
(numeric
of length 2) The number of increments in each dimension.
(function
) A function that takes two arguments, the max and min, and
returns the optimality statistic.
(function
) A function that takes a list of opt_crit
outputs
and returns the index of the best one.