
Package index
Input layer
Validation and grain helpers for raw experience data. as_triangle() already runs the required checks and coercions inline — these helpers are exposed for users who want to validate or enrich without building a triangle.
-
derive_grain_columns() - Derive monthly / quarterly / semi-annual / annual grain columns
-
validate_triangle() - Validate triangle structure before building a development
Aggregation builders
Three frameworks for viewing the same long-format experience data — cohort × dev (Triangle), calendar period (Calendar), or portfolio total (Total).
-
as_triangle() - Coerce experience data to a Triangle object
-
as_calendar() - Coerce experience data to a Calendar object
-
as_total() - Coerce experience data to a Total object
Link table
Long-format intermediate underlying both the chain-ladder (ATA) and exposure-driven (ED) workflows. Built once, summarised differently via summary.Link()’s model argument.
-
as_link() - Coerce a Triangle to a Link object
-
summary(<Link>) - Summarise a
Linktable
Estimation
Models that produce full projections on a Triangle. Base algorithms: fit_cl (chain ladder / multiplicative), fit_ed (exposure-driven / additive), fit_sa (stage-adaptive composition of ED + CL anchored on a maturity point). ELR-based reserve methods: fit_bf (Bornhuetter-Ferguson with external prior), fit_cc (Cape Cod with data-pooled ELR estimate). Role dispatchers: fit_loss (loss-side ed/cl/sa/bf/cc), fit_premium (premium-side ed/cl). Composition: fit_ratio (loss-ratio umbrella with delta-method SE). All return an object carrying a $full projection table.
-
fit_cl() - Fit chain ladder projection from a
Triangleobject -
fit_ed() - Fit ED intensity factors
-
fit_sa() - Fit stage-adaptive (SA) loss projection on a Triangle
-
fit_bf() - Bornhuetter-Ferguson projection
-
fit_cc() - Cape Cod projection (Stanard 1985)
-
fit_loss() - Fit a loss projection on a Triangle
-
fit_premium() - Fit a chain ladder projection on the premium triangle
-
fit_ratio() - Fit loss ratio projection model
Factor diagnostics
Per-link factor estimation at the factor level. Both fit_ata (multiplicative ATA factors f_k) and fit_intensity (ED-style additive intensities g_k) return per-link factors with standard errors and diagnostic stats — without producing a full projection. fit_ata feeds into fit_cl, detect_maturity(), and the SA stage transition in fit_ratio; fit_intensity feeds into fit_ed and is the ED counterpart diagnostic.
-
fit_ata() - Fit age-to-age development factors
-
fit_intensity() - Fit per-link ED intensity factors
Cell-selection diagnostics
Decide which cells of the triangle to use for estimation. detect_maturity works along the dev axis (link beyond which ATA factors are stable); detect_regime works along the cohort axis (structural break across underwriting cohorts). The *_at() / *_spec() helpers build manual / lazy-detect input objects for the maturity / loss_regime / premium_regime arguments of the fit functions.
-
detect_maturity() - Find ata maturity by group
-
detect_regime()print(<Regime>)summary(<Regime>)print(<summary.Regime>) - Detect structural regime shifts across underwriting cohorts
-
maturity_at() - Construct a Maturity object from manually specified maturity points
-
maturity_spec() - Build a lazy maturity detection spec
-
regime_at() - Construct a Regime object from manually specified regime changes
-
regime_spec() - Build a lazy regime detection spec
Bootstrap
Cohort × dev standard-error decomposition via simulation (Pythagorean split into parameter and process components). Returned object is consumed by fit_loss / fit_premium / fit_ratio through their bootstrap argument to replace analytical SE / CI with empirical counterparts.
-
bootstrap() - Bootstrap a Triangle
Projection diagnostic
Operates on a fitted RatioFit, not on the raw triangle. Locates the valuation depth at which the projected ultimate loss ratio stops revising under a dual criterion (predictive revision below noise threshold AND cross-cohort dispersion small, sustained over M consecutive valuations).
-
detect_convergence() - Find the development period at which the loss ratio estimate stabilises
Backtest
Hold out the latest calendar diagonals from a triangle, refit, and compare projections against the withheld actuals.
-
backtest()print(<Backtest>)summary(<Backtest>)print(<summary.Backtest>) - Backtest a loss / premium / loss-ratio projection on existing data
Visualisation
plot() (base generic) and plot_triangle() (lossratio generic) dispatch on the object class. render() is a console table renderer for data frames and Triangle objects.
-
plot_triangle() - Triangle plot generic
-
plot(<ATAFit>) - Plot an ata fit
-
plot(<BFFit>) - Plot a Bornhuetter-Ferguson fit
-
plot(<Backtest>) - Plot a backtest object
-
plot(<CCFit>) - Plot a Cape Cod fit
-
plot(<CLFit>) - Plot a chain ladder fit
-
plot(<Calendar>) - Plot calendar-based development statistics
-
plot(<Convergence>) - Plot the Convergence diagnostic
-
plot(<EDFit>) - Plot an ED fit
-
plot(<IntensityFit>) - Plot an Intensity fit
-
plot(<Link>) - Plot link-factor diagnostics
-
plot(<PremiumFit>) - Plot an premium fit
-
plot(<RatioFit>) - Plot a loss ratio fit
-
plot(<Regime>) - Plot a cohort regime detection result
-
plot(<RegimeOptimalWindow>) - Plot change-count vs window with the elbow marker
-
plot(<SAFit>) - Plot a stage-adaptive fit
-
plot(<Total>) - Plot a
Totalobject as a per-group bar chart -
plot(<Triangle>) - Plot development trajectories with optional summary overlay
-
plot(<TriangleValidation>) - Plot a TriangleValidation result
-
plot_triangle(<ATAFit>) - Triangle heatmap for an ata fit
-
plot_triangle(<BFFit>) - Plot a Bornhuetter-Ferguson fit as a triangle table
-
plot_triangle(<Backtest>) - Triangle heatmap of backtest A/E Error
-
plot_triangle(<CCFit>) - Plot a Cape Cod fit as a triangle table
-
plot_triangle(<CLFit>) - Plot a chain ladder fit as a triangle table
-
plot_triangle(<EDFit>) - Triangle heatmap for an ED fit
-
plot_triangle(<IntensityFit>) - Triangle heatmap for an Intensity fit
-
plot_triangle(<Link>) - Plot a Link object as a triangle heatmap
-
plot_triangle(<PremiumFit>) - Plot an premium fit as a triangle table
-
plot_triangle(<RatioFit>) - Plot loss ratio projection as a triangle heatmap
-
plot_triangle(<SAFit>) - Plot a stage-adaptive fit as a triangle table
-
plot_triangle(<Triangle>) - Plot development values as a triangle table
-
plot_triangle(<TriangleValidation>) - Triangle-heatmap view of dev-sequence gaps
-
render()print(<Triangle>) - Render a tabular object as a compact console table
-
backtest()print(<Backtest>)summary(<Backtest>)print(<summary.Backtest>) - Backtest a loss / premium / loss-ratio projection on existing data
-
detect_regime()print(<Regime>)summary(<Regime>)print(<summary.Regime>) - Detect structural regime shifts across underwriting cohorts
-
print(<ATAFit>) - Print an
ATAFitobject -
print(<ATASummary>) - Print method for
ATASummary -
print(<BFFit>) - Print method for
BFFit -
print(<BootstrapTriangle>) - Print method for BootstrapTriangle
-
print(<CCFit>) - Print method for
CCFit -
print(<CLFit>) - Print a
CLFitobject -
print(<EDFit>) - Print an
EDFitobject -
print(<EDSummary>) - Print method for
EDSummary -
print(<IntensityFit>) - Print method for
IntensityFit -
print(<LossFit>) - Print method for
LossFit -
print(<PremiumFit>) - Print method for
PremiumFit -
print(<RatioFit>) - Print an
RatioFitobject -
print(<SAFit>) - Print method for
SAFit -
render()print(<Triangle>) - Render a tabular object as a compact console table
-
summary(<ATAFit>) - Summary method for
ATAFit -
summary(<BFFit>) - Summary method for
BFFit -
summary(<CCFit>) - Summary method for
CCFit -
summary(<CLFit>) - Summary method for
CLFit -
summary(<Calendar>) - Summarise calendar-development statistics (Mean, Median, Weighted)
-
summary(<EDFit>) - Summary method for
EDFit -
summary(<IntensityFit>) - Summary method for
IntensityFit -
summary(<Link>) - Summarise a
Linktable -
summary(<LossFit>) - Summary method for
LossFit -
summary(<PremiumFit>) - Summary method for
PremiumFit -
summary(<RatioFit>) - Summary method for
RatioFit -
summary(<SAFit>) - Summary method for
SAFit -
summary(<Total>) - Summarise a
Totalobject -
summary(<Triangle>) - Summarise development statistics (Mean, Median, Weighted)
-
longer() - Reshape an object to long form (S3 generic)
-
mask_triangle() - Mask the last N calendar diagonals from a Triangle
-
experience - Sample loss experience data