RAA
MCL=MackChainLadder(RAA)
MCL
plot(MCL)
# BootChainLadder
B <- BootChainLadder(RAA, R=999, process.distr="gamma")
B
plot(B)
# fitdistribution
library(MASS)
# fit a log-normal distribution
fit <- fitdistr(B$IBNR.Totals, "lognormal")
fit
plot(ecdf(B$IBNR.Totals))
curve(plnorm(x,fit$estimate["meanlog"], fit$estimate["sdlog"]), col="red", add=TRUE)
# Munich Chain Ladder
MCLpaid
MCLincurred
MCL = MunichChainLadder(MCLpaid, MCLincurred)
MCL
plot(MCL)
Run the code above in your browser using DataLab