Learn R Programming

evgam (version 1.0.2)

evgam.control: Create control parameters for evgam fitting

Description

Defines and updates optimization settings for both the inner and outer iterations used in extreme value generalized additive models (`evgam`).

Usage

evgam.control(inner = NULL, outer = NULL)

Value

A nested named list with two components: outer and

inner. Each component contains the finalized tuning values used by the fitting algorithms.

Arguments

inner

An optional named list of control parameters to override the default values for the inner optimization loop. Defaults to NULL.

outer

An optional named list of control parameters to override the default values for the outer optimization loop. Defaults to NULL.

Details

The function returns a nested list containing settings for outer and inner optimization. Each sub-list can configure the following parameters:

  • steptol Minimum step length tolerance. Iteration terminates if steps fall below this value. Defaults: outer = 1e-12, inner = 1e-12.

  • itlim Maximum number of iterations allowed. Defaults: outer = 100, inner = 100.

  • fntol Relative function convergence tolerance. Defaults: outer = 1e-8, inner = 1e-8.

  • gradtol Convergence tolerance for the mean absolute gradient. Defaults: outer = 1e-2, inner = 1e-4.

  • stepmax Maximum allowable step length scaled to prevent excessive jumps. Defaults: outer = 3, inner = 100.

  • alpha0 Initial step length factor for backtracking line searches. Defaults: outer = 10, inner = 1.

  • dgradtol Derivative gradient tolerance threshold. Defaults: outer = 1e-4, inner = 1e-6.

Examples

Run this code
# Generate default control parameters
default_control <- evgam.control()

# Customise specific inner loop parameters
custom_control <- evgam.control(inner = list(itlim = 500, gradtol = 1e-6))

Run the code above in your browser using DataLab