findmax: Find Maximum

View source: R/utils.R

findmaxR Documentation

Find Maximum

Description

Searches the location of the maximum of a sensitivity function over the design space. For single-factor models the search uses a regular grid followed by direct selection. For multi-factor models a Latin Hypercube Sample is evaluated and then refined with L-BFGS-B local optimisation from the n_starts best candidate points.

Usage

findmax(sens, design_space, grid.length, n_starts = 5L)

Arguments

sens

Sensitivity function (scalar for 1D, named numeric vector for multi-factor).

design_space

Numeric vector c(min, max) or named list.

grid.length

Number of grid / LHS points for the initial sweep.

n_starts

Number of local-optimisation restarts (multi-factor only).

Value

The design point (scalar or named numeric vector) at which sens is maximised.


optedr documentation built on June 23, 2026, 5:07 p.m.