Skip to contents

This is intended for a specialized external optimizer whose result should enter the same portable fitted-model lifecycle as sbt_optimise(). Normal workflows should use sbt_optimise() directly.

Usage

sbt_add_optimisation(
  fit,
  opt,
  estimability = NULL,
  diagnostics = list(),
  optimizer = NULL,
  check = TRUE,
  check_args = list()
)

Arguments

fit

An sbt_fit() object.

opt

Optimizer result containing named finite par, a finite objective, and an integer-like convergence code.

estimability

Optional result from check_estimability().

diagnostics

Optional named list of optimizer diagnostics.

optimizer

Optional non-empty optimizer description. The description already stored in fit is used when omitted.

check

Run check_mle() after attachment.

check_args

Named arguments passed to check_mle().

Value

The optimized sbt_fit.