Repository navigation
Description
Taylor's separation method splits an incremental triangle of paid amount per claim into a development pattern r_j and a calendar-year index λ_{i+j}, so each cell's expected value is r_j λ_{i+j}. The user then picks future values of λ, for example a constant inflation rate, and the method completes the triangle. Verbeek 1972 derived the same estimates as Poisson maximum likelihood for claim counts.
chainladder has no estimator for this today. TweedieGLM with C(development) + C(valuation) has the same structure, but its fit raises a PatsyError because the projected cells need calendar levels that the data never saw. A linear valuation term or BarnettZehnwirth fits one trend rate instead of a free index for each calendar year.
The snippet below reproduces Example 1 in section 10 of Taylor 1977 with his equations 5 and 6. It gives r = 0.5835, 0.2878, 0.0866, 0.0421 and λ = 86.4, 98.9, 102.0, 113.9, which match the paper. With the index growing 10% a year after the latest diagonal, the completed square matches Taylor's rectangle to one decimal in every cell but one, where the snippet prints 10.9 and the paper prints 10.8.
r [0.5835 0.2878 0.0866 0.0421]
lambda [ 86.4 98.9 102. 113.9]
[[50.4 28.5 8.8 4.8]
[57.7 29.4 9.9 5.3]
[59.5 32.8 10.9 5.8]
[66.5 36.1 11.9 6.4]]
PatsyError
Code snippet
import chainladder as cl
import numpy as np
import pandas as pd
import patsy
# Taylor (1977), section 10, Example 1. Incremental paid amount per claim.
s = [[50.4, 28.2, 9.0, 4.8], [58.0, 29.2, 9.7], [59.5, 33.2], [66.2]]
rows = [
{"origin": str(2000 + i), "valuation": str(2000 + i + j), "s": v}
for i, row in enumerate(s)
for j, v in enumerate(row)
]
tri = cl.Triangle(
pd.DataFrame(rows),
origin="origin",
valuation="valuation",
columns="s",
cumulative=False,
)
# Equations (5) and (6), working back from the latest diagonal.
a = tri.values[0, 0]
k = a.shape[0] - 1
lam = np.zeros(k + 1)
r = np.zeros(k + 1)
for h in range(k, -1, -1):
d = sum(a[i, h - i] for i in range(h + 1))
lam[h] = d / (1 - r[h + 1 :].sum())
r[h] = np.nansum(a[:, h]) / lam[h:].sum()
print("r ", np.round(r, 4))
print("lambda", np.round(lam, 1))
# Section 10 assumes the index grows 10% a year after the latest diagonal.
lam_all = np.concatenate([lam, lam[-1] * 1.1 ** np.arange(1, k + 1)])
square = np.array([[r[j] * lam_all[i + j] for j in range(k + 1)] for i in range(k + 1)])
print(np.round(square, 1))
# TweedieGLM fits a calendar term but cannot project an unseen calendar level.
glm = cl.TweedieGLM(
design_matrix="C(development) + C(valuation)", power=1, alpha=0, max_iter=1000
)
try:
glm.fit(tri)
except patsy.PatsyError as e:
print(type(e).__name__)One shape could be a development estimator that takes an incremental triangle, an optional claim-count triangle for Taylor's n_i in section 4, and a future index as a rate or a sequence. The tail beyond the oldest age in section 8, equation 9, would need its own option. Björkwall, Hössjer and Ohlsson 2010 later bootstrapped the method, so a stochastic version could follow.
Would this fit the library? I can draft it if so.
References
- Taylor, G. C., 1977. Separation of inflation and other effects from the distribution of non-life insurance claim delays. ASTIN Bulletin 9, 219–230. https://doi.org/10.1017/S0515036100011533
- Verbeek, H. G., 1972. An approach to the analysis of claims experience in motor liability excess of loss reassurance. ASTIN Bulletin 6, 195–202.
- Björkwall, S., Hössjer, O. and Ohlsson, E., 2010. Bootstrapping the separation method in claims reserving. ASTIN Bulletin 40, 845–869.
(This issue was written with Árbol, an AI assistant, under my direction.)
Metadata
Metadata
Assignees
Labels
Type
Fields
Priority
Scope
Effort
Projects
- StatusShow more project fieldsNot Ready
Activity