Assemble a list of objective descriptors ready for consumption by the optimization engine. Built-in metrics are pulled from the registry created in build_objectives(); custom entries may be appended for experimental goals.

define_objectives(
  metrics = c("sensitivity", "specificity"),
  custom = NULL,
  params = list(),
  directions = NULL,
  cutoff_strategy = c("fixed", "prevalence", "youden"),
  cutoff_prob = 0.5
)

Arguments

metrics

Character vector of registered metric names (default: c("sensitivity", "specificity")).

custom

Optional named list of objective descriptors with elements label, direction, and fun.

params

Named list of additional argument lists for specific metrics (e.g., custom cutoff probabilities for sensitivity).

directions

Optional named vector overriding metric directions.

cutoff_strategy

Strategy for computing classification cutoff. One of:

"fixed"

Use cutoff_prob parameter (default 0.5)

"prevalence"

Cutoff equals training class prevalence

"youden"

Optimal Youden's J point from ROC curve

cutoff_prob

Fixed cutoff probability (default 0.5). Only used when cutoff_strategy = "fixed".

Value

Named list of objective descriptors.