Expert Functions
The LRMoE.jl package supports a collection of distributions commonly used for modelling insurance claim frequency and severity.
Discrete Distributions (Frequency Modelling)
LRMoE.BinomialExpert
— TypeBinomialExpert(n, p)
PMF:
\[P(X = k) = {n \choose k}p^k(1-p)^{n-k}, \quad \text{ for } k = 0,1,2, \ldots, n.\]
See also: Binomial Distribution (Wikipedia)
LRMoE.NegativeBinomialExpert
— TypeNegativeBinomialExpert(n, p)
PMF:
\[P(X = k) = \frac{\Gamma(k+r)}{k! \Gamma(r)} p^r (1 - p)^k, \quad \text{for } k = 0,1,2,\ldots.\]
See also: Negative Binomial Distribution (Wolfram)
LRMoE.PoissonExpert
— TypePoissonExpert(λ)
PMF:
\[P(X = k) = \frac{\lambda^k}{k!} e^{-\lambda}, \quad \text{ for } k = 0,1,2,\ldots.\]
See also: Poisson Distribution (Wikipedia)
LRMoE.GammaCountExpert
— TypeGammaCountExpert(m, s)
PMF:
\[P(X = k) = G(m k, s T) - G(m (k+1), s T), \quad \text{ for } k = 0,1,2, \ldots, n.\]
with
\[G(m k, s T) = \frac{1}{\Gamma(mk)} \int^{sT}_{0} u^{mk - 1} e^{-u} du\]
See also: Gamma Count Distribution (Arxiv)
Continuous Distributions (Severity Modelling)
LRMoE.BurrExpert
— TypeBurrExpert(k, c, λ)
PDF:
\[f(x; k, c, \lambda) = \frac{kc}{\lambda} \left( \frac{x}{\lambda} \right)^{c-1} \left( 1+ \left( \frac{x}{\lambda} \right)^{c} \right)^{-k-1}, \quad x \geq 0\]
See also: Burr Distribution (Mathworks, implemented in this package), Burr Distribution (Wikipedia, with λ = 1)
LRMoE.GammaExpert
— TypeGammaExpert(k, θ)
PDF:
\[f(x; k, \theta) = \frac{x^{k-1} e^{-x/\theta}}{\Gamma(k) \theta^k}, \quad x > 0\]
See also: Gamma Distribution (Wikipedia), shape-scale parameterization
LRMoE.InverseGaussianExpert
— TypeInverseGaussianExpert(μ, λ)
PDF:
\[f(x; \mu, \lambda) = \sqrt{\frac{\lambda}{2\pi x^3}} \exp\left(\frac{-\lambda(x-\mu)^2}{2\mu^2x}\right), \quad x > 0\]
See also: Inverse Gaussian Distribution (Wikipedia)
LRMoE.LogNormalExpert
— TypeLogNormalExpert(μ, σ)
PDF:
\[f(x; \mu, \sigma) = \frac{1}{x \sqrt{2 \pi \sigma^2}} \exp \left( - \frac{(\log(x) - \mu)^2}{2 \sigma^2} \right), \quad x > 0\]
See also: Lognormal Distribution (Wikipedia)
LRMoE.WeibullExpert
— TypeWeibullExpert(k, θ)
PDF:
\[f(x; k, \theta) = \frac{k}{\theta} \left( \frac{x}{\theta} \right)^{k-1} e^{-(x/\theta)^k}, \quad x \geq 0\]
See also: Weibull Distribution (Wikipedia)
Zero Inflation
Zero inflation is supported for all discrete and continuous experts. They can be constructed by adding ZI
in front of an expert function, with an additional parameter p
(or p0
if the expert already uses p
, e.g. binomial) for modelling a probability mass at zero. Zero-inflated experts are used in the same way as their non-zero-inflated counterpart. A complete list of zero-inflated expert functions is given below.
ZIBinomialExpert(p0, n, p)
ZINegativeBinomialExpert(p0, n, p)
ZIPoissonExpert(p, λ)
ZIGammaCountExpert(p, m, s)
ZIBurrExpert(p, k, c, λ)
ZIGammaExpert(p, k, θ)
ZIInverseGaussianExpert(p, μ, λ)
ZILogNormalExpert(p, μ, σ)
ZIWeibullExpert(p, k, θ)
Adding Customized Expert Functions
See here.