Learn R Programming

ChainLadder (version 0.1.7)

chainladder: Estimate age-to-age factors

Description

Basic chain ladder function to estimate age-to-age factors for a given cumulative run-off triangle. This function is used by Mack- and MunichChainLadder.

Usage

chainladder(Triangle, weights = 1, delta = 1)

Arguments

Triangle
cumulative claims triangle. A (mxn)-matrix $C_{ik}$ which is filled for $k \leq n+1-i; i=1,\ldots,m; m\geq n$, see qpaid for how to use (mxn)-development triangles with m
weights
weights. Default: 1, which sets the weights for all triangle entries to 1. Otherwise specify weights as a matrix of the same dimension as Triangle with all weight entries in [0; 1]
delta
'weighting' parameters, either 0,1 or 2. Default: 1; delta=1 gives the historical chain ladder age-to-age factors, delta=2 gives the straight average of the observed individual development factors and delta=0 is the result of an ordinary r

Value

  • chainladder returns a list with the following elements:
  • Modelslinear regression models for each development period
  • Triangleinput triangle of cumulative claims
  • weightsweights used
  • deltadeltas used

Details

The key idea is to see the chain ladder algorithm as a weighted linear regression through the origin applied to each development period.

Suppose y is the vector of cumulative claims at development period i+1, and x at development period i, w are weighting factors and F the individual age-to-age factors F=y/x, than we get the various age-to-age factors for different deltas (alphas) as:

sum(w*x^alpha*F)/sum(w*x^alpha) # Mack (1999) notation delta <- 2-alpha lm(y~x + 0 ,weights=w/x^delta) # Barnett & Zehnwirth (2000) notation

References

Thomas Mack. The standard error of chain ladder reserve estimates: Recursive calculation and inclusion of a tail factor. Astin Bulletin. Vol. 29. No 2. 1999. pp.361:366

G. Barnett and B. Zehnwirth. Best Estimates for Reserves. Proceedings of the CAS. Volume LXXXVII. Number 167. November 2000.

See Also

See also ata, predict.ChainLadder MackChainLadder,

Examples

Run this code
## Concept of different chain ladder age-to-age factors.
## Compare Mack's and Barnett & Zehnwirth's papers.
x <- RAA[1:9,1]
y <- RAA[1:9,2]

weights <- RAA
weights[!is.na(weights)] <- 1
w <- weights[1:9,1]

F <- y/x
## wtd. average chain ladder age-to-age factors
alpha <- 1
delta <- 2-alpha

sum(w*x^alpha*F)/sum(w*x^alpha)
lm(y~x + 0 ,weights=w/x^delta)
summary(chainladder(RAA, weights=weights, delta=delta)$Models[[1]])$coef

## straight average age-to-age factors
alpha <- 0
delta <- 2 - alpha 
sum(w*x^alpha*F)/sum(w*x^alpha)
lm(y~x + 0 ,weights=w/x^(2-alpha))
summary(chainladder(RAA, weights=weights, delta=delta)$Models[[1]])$coef

## ordinary regression age-to-age factors
alpha=2
delta <- 2-alpha
sum(w*x^alpha*F)/sum(w*x^alpha)
lm(y~x + 0 ,weights=w/x^delta)
summary(chainladder(RAA, weights=weights, delta=delta)$Models[[1]])$coef

## Change weights

weights[2,1] <- 0.5
w <- weights[1:9,1] 

## wtd. average chain ladder age-to-age factors
alpha <- 1
delta <- 2-alpha
sum(w*x^alpha*F)/sum(w*x^alpha)
lm(y~x + 0 ,weights=w/x^delta)
summary(chainladder(RAA, weights=weights, delta=delta)$Models[[1]])$coef

## straight average age-to-age factors
alpha <- 0
delta <- 2 - alpha 
sum(w*x^alpha*F)/sum(w*x^alpha)
lm(y~x + 0 ,weights=w/x^(2-alpha))
summary(chainladder(RAA, weights=weights, delta=delta)$Models[[1]])$coef

## ordinary regression age-to-age factors
alpha=2
delta <- 2-alpha
sum(w*x^alpha*F)/sum(w*x^alpha)
lm(y~x + 0 ,weights=w/x^delta)
summary(chainladder(RAA, weights=weights, delta=delta)$Models[[1]])$coef

## Model review
CL0 <- chainladder(RAA, weights=weights, delta=0)
## age-to-age factors
sapply(CL0$Models, function(x) summary(x)$coef["x","Estimate"])
## f.se
sapply(CL0$Models, function(x) summary(x)$coef["x","Std. Error"])
## sigma
sapply(CL0$Models, function(x) summary(x)$sigma)

CL1 <- chainladder(RAA, weights=weights, delta=1)
## age-to-age factors
sapply(CL1$Models, function(x) summary(x)$coef["x","Estimate"])
## f.se
sapply(CL1$Models, function(x) summary(x)$coef["x","Std. Error"])
## sigma
sapply(CL1$Models, function(x) summary(x)$sigma)

CL2 <- chainladder(RAA, weights=weights, delta=2)
## age-to-age factors
sapply(CL2$Models, function(x) summary(x)$coef["x","Estimate"])
## f.se
sapply(CL2$Models, function(x) summary(x)$coef["x","Std. Error"])
## sigma
sapply(CL2$Models, function(x) summary(x)$sigma)


## Forecasting

predict(CL0)
predict(CL1)
predict(CL2)

Run the code above in your browser using DataLab