Skip to contents

Estimate per-development-link incremental loss intensities \(g_k = \mathbb{E}[\Delta L_k / C^P_k]\) from a "Triangle" and return an "IntensityFit" object that bundles the link-level WLS-estimated intensities along with their standard errors and diagnostic statistics.

This is the factor-level diagnostic for the exposure-driven (ED) workflow, parallel to fit_ata() for the multiplicative (chain ladder) side. Both operate at the factor level without producing a full projection. For full ED projection (cumulative loss / premium / ratio), use fit_ed() which accepts either a Triangle or an IntensityFit (skipping a rebuild of the link table when factors are already computed).

Usage

fit_intensity(
  x,
  loss = "loss",
  exposure = "premium",
  alpha = 1,
  na_method = c("locf", "zero", "none"),
  sigma_method = c("locf", "min_last2", "loglinear", "mack", "none"),
  recent = NULL,
  regime = NULL,
  ...
)

Arguments

x

A Triangle object.

loss

A single cumulative metric used as the link numerator. Default "loss".

exposure

A single cumulative metric used as the exposure base (denominator anchor). Default "premium".

alpha

WLS weight exponent. Default 1.

na_method

NA fill method for the selected intensity series used downstream by fit_ed(). One of "locf" (default – carries the last observed intensity forward, appropriate for long-term health where ageing keeps \(g_k\) elevated rather than decaying to 0), "zero" (sets late-dev NAs to 0; suits short-tail lines where claims fully settle), or "none".

sigma_method

Method used to extrapolate sigma for links where it cannot be estimated. One of "locf" (default), "min_last2", "loglinear", "mack", or "none". "mack" applies the Mack (1993, Appendix B) tail estimator to the last unestimated link only, falling back to LOCF for any earlier ones with a warning. "none" performs no extrapolation; sigma stays NA and downstream variance terms drop those links via finite-value guards. Passed to .extrapolate_sigma_ata().

recent

Optional positive integer. When supplied, restricts estimation to rows within the last recent calendar diagonals (calendar-diagonal wedge filter; see .apply_recent_filter()).

regime

Optional regime specification for cohort cutoff. Accepts: NULL (default – no filter), a "Regime" object (from detect_regime()), the string "auto" (internal detect_regime(tri, loss = "ratio") call), or a function function(tri) -> Regime. Resolved internally via .resolve_regime(). When supplied, cohorts strictly before the change are dropped before estimation.

...

Passed to summary.Link() (e.g. digits).

Value

A list of class "IntensityFit" with components:

call

The matched call.

data

The (possibly filtered) Link object used for estimation.

groups, cohort, dev, loss, premium

Variable name relays from the input Triangle.

link

Alias of data for parallelism with fit_ata().

factor

The EDSummary returned by summary.Link() – one row per link with WLS-estimated g, g_se, rse, sigma, plus descriptive statistics.

selected

data.table of selected intensities per link (g_sel, sigma, sigma2, sigma_extrapolated). LOCF NA-fill is applied when na_method = "locf"; sigma extrapolation is applied per sigma_method.

alpha, na_method, sigma_method, recent, regime

Call metadata. regime is the resolved "Regime" object (or NULL) returned by .resolve_regime().

ED has no maturity concept

Unlike ATA factors, where CV / RSE drive a detect_maturity() threshold, ED intensities behave differently – as \(g_k \to 0\) in late development the CV / RSE blow up by construction, not by instability. fit_intensity() therefore deliberately omits a maturity parameter, and detect_maturity() rejects IntensityFit input with an informative error.

Examples

if (FALSE) { # \dontrun{
tri <- as_triangle(
  df,
  groups   = "coverage",
  cohort   = "uy_m",
  calendar = "cy_m",
  loss     = "incr_loss",
  premium  = "incr_premium"
)
intensity_fit <- fit_intensity(tri, loss = "loss", exposure = "premium")
summary(intensity_fit)
} # }