slct_psi: PSI selector

View source: R/slct_psi.R

slct_psiR Documentation

PSI selector

Description

Accepts a stored concept when the mean PSI over the features between the current batch and the concept's memory is within its limit, and selects the accepted concept with the smallest PSI (or PSI/limit ratio, see rank_by). No accepted concept: a new one is created.

Usage

slct_psi(
  max_psi = NULL,
  tol_quantile = 0.8,
  numerical_cols = NULL,
  n_tiles = 10,
  rank_by = c("psi", "ratio")
)

Arguments

max_psi

Fixed PSI limit for every concept (e.g. 0.25). NULL (default): learned for each concept as the tol_quantile quantile of the PSI of the batches that belonged to it.

tol_quantile

Quantile of the learned limit.

numerical_cols

Names of the numerical features. NULL: every numeric column; the other columns are treated as categorical.

n_tiles

Number of quantile bins of the numerical PSI.

rank_by

Order of the accepted concepts: "psi" (smallest PSI) or "ratio" (smallest PSI/limit, ties broken by the PSI). Both coincide with a fixed max_psi.

Value

A slct_psi object.


heimdall documentation built on Dec. 2, 2026, 5:08 p.m.