## read from file claims <- scan("/home/wkarcher/Desktop/claims.dat") ## estimate mean residual hazard (life) function library(evd) mrlplot(claims, xlim=c(0,20000),ylim=c(4000,15000)) ## Q-Q plots for the gamma, the lognormal and the Weibull distribution quant <- 1/10001*(1:10000) gamma <- qgamma(quant, shape=1, scale=4429) lognormal <- qlnorm(quant, meanlog=8, sdlog=1) weibull <- qweibull(quant, shape=1, scale=4792) qqplot(claims, gamma, main="Q-Q Plot for the gamma distribution") qqplot(claims,lognormal, main="Q-Q Plot for the lognormal distribution") qqplot(claims,weibull, main="Q-Q Plot for the Weibull distribution")