Library: | insurance |
See also: | INSwei INSlogn INSpareto INSbur |
Quantlet: | INSgam | |
Description: | returns the pure risk premium for Gamma distribution of losses. |
Usage: | y = INSgam(b,d2,d1,c,m2,m1,alpha,beta,ind) | |
Input: | ||
b | n x 1 vector, deductible (in case of fixed deductible, franchise deductible or proportional deductible) | |
d2 | n x 1 vector, maximum amount, d2>d1, of linear reduction for disappearing deductible | |
d1 | scalar, minimum amount of linear reduction for disappearing deductible | |
c | scalar, deductible (in case of limited proportional deductible) | |
m2 | n x 1 vector, maximum amount, m2>m1, for limited proportional deductible | |
m1 | scalar, minimum amount for limited proportional deductible | |
alpha | scalar, parameter alpha from Weibull distribution | |
beta | scalar, parameter beta from Weibull distribution | |
ind | scalar, if ind=1, franchise deductible if ind=2, fixed amount deductible if ind=3, proportional deductible if ind=4, limited proportional deductible if ind=5, disappearing deductible | |
Output: | ||
y | n x 1 vector, value of the pure risk premium for Gamma distribution of losses |
library("insurance") library("distribs") library("plot") alpha=0.9796 ;alpha parameter in Gamma distribution beta=1.6348*(10^8) ;beta parameter in Gamma distribution a=(0:100)*10000000 ;argument in payment functions u1=INSgam(a,0,0,0,0,0,alpha,beta,1) u2=INSgam(a,0,0,0,0,0,alpha,beta,2) s1 = setmask(a/1000000~u1/1000000,"line","black") s2=setmask(a/1000000~u2/1000000,"line","red") plotdisplay = createdisplay(1,1) show(plotdisplay,1,1,s1,s2) setgopt(plotdisplay,1,1,"xmajor",200,"ymajor",50) setgopt(plotdisplay,1,1,"yvalue",0|1) setgopt(plotdisplay,1,1,"xvalue",0|1) setgopt(plotdisplay,1,1,"border",0) setgopt(plotdisplay,1,1, "xlabel", "Deductible(USD million)", "ylabel", " Premium(USD million)") setgopt(plotdisplay,1,1,"title","Pure Risk Premium - Gamma")
Plot of pure risk premium under franchise deductible (black) and fixed amount deductible (red).
library("insurance") library("distribs") library("plot") alpha=0.9796 ;alpha parameter in Gamma distribution beta=1.6348*(10^8) ;beta parameter in Gamma distribution m2=(20:100)*10000000 ;argument in payment functions c1=0.2 ;parameters c and m1 in the case of limited proportional deductible c2=0.4 m11=100000000 m12=500000 u1=INSgam(0,0,0,c1,m2,m11,alpha,beta,4) u2=INSgam(0,0,0,c2,m2,m11,alpha,beta,4) u3=INSgam(0,0,0,c1,m2,m12,alpha,beta,4) u4=INSgam(0,0,0,c2,m2,m12,alpha,beta,4) s1 = setmask(m2/1000000~u1/1000000,"line","black") s2=setmask(m2/1000000~u2/1000000,"line","red") s3 = setmask(m2/1000000~u3/1000000,"line","green") s4=setmask(m2/1000000~u4/1000000,"line","blue") plotdisplay = createdisplay(1,1) show(plotdisplay,1,1,s1,s2,s3,s4) setgopt(plotdisplay,1,1,"xlim",200|1000) setgopt(plotdisplay,1,1,"xmajor",200) setgopt(plotdisplay,1,1,"yvalue",0|1) setgopt(plotdisplay,1,1,"xvalue",0|1) setgopt(plotdisplay,1,1,"border",0) setgopt(plotdisplay,1,1, "xlabel", "Deductible(USD million)", "ylabel", " Premium(USD million)") setgopt(plotdisplay,1,1,"title","Pure Risk Premium - Gamma")
Plots of pure risk premium under limited proportional deductible with parameters: c1,m11 (black), c2,m11 (red), c1,m12 (green) and c2,m12 (blue).