Parametric Mortality Models
Introduction
Parametric mortality models are not collections of annual rates, but rather construct a mathematical representation of a mortality curve.
They are often used underlying traditional table construction, but are converted to a list of annual rates for convenience in practice. MortalityTables.jl
provides them and are essentially interchangeable versus the traditional table structure in most use cases.
Many of these models were adapted from the MortalityLaws R package, by Marius Pascariu & Vladimir Canudas-Romo.
Usage Example
Use like so:
a = 0.0002
b = 0.13
c = 0.001
m = MortalityTables.Makeham(a=a,b=b,c=c)
g = MortalityTables.Gompertz(a=a,b=b)
Now some examples with m
, but could use g
interchangeably:
age = 20
m[20] # the mortality rate at age 20
decrement(m,20,25) # the five year cumulative mortality rate
survival(m,20,25) # the five year survival rate
Other notes
- Because of the large number of models and the likelihood for overlap with other things (e.g.
Quadratic
orWeibull
would be expected to be found in other contexts as well), these models Are not exported from the package, so you need to call them by prefixing withMortalityTables
.- e.g. :
MortalityTables.Kostaki()
- e.g. :
- Because of the large number of parameters for the models, the arguments are keyword rather than positional:
MortalityTables.Gompertz(a=0.01,b=0.2)
- The models have default values, so they can be called without args like this:
MortalityTables.Gompertz()
.- See the help text for what the default values are:
?Gompertz
- See the help text for what the default values are:
Functions
Many of the models only have analytical forms for either the hazard
or survival
curve. You can still call either on any of the models, as MortalityTables with numerically integrate or automatic differentiate as appropriate.
MortalityTables.hazard
— Functionhazard(model,age)
The force of mortality at age
. More precisely: the ratio of the probability of failure/death to the survival function.
MortalityTables.cumhazard
— Functioncumhazard(model,age)
The cumulative force of mortality at age
. More precisely: the ratio of the cumulative probability of failure/death to the survival function.
MortalityTables.μ
— Functionμ(;m::ParametricMortality,age)
$\mu_x$: Return the force of mortality at the given age.
Also see survival
and decrement
.
Available Models
These models are subtypes of ParametricMortality
:
MortalityTables.Makeham
— TypeMakeham(;a,b,c)
Construct a mortality model following Makeham's law.
$\mathrm{hazard} \left( {\rm age} \right) = ae^{bx} + c$
Default args:
a = 0.0002
b = 0.13
c = 0.001
MortalityTables.Gompertz
— FunctionGompertz(;a,b)
Construct a mortality model following Gompertz' law of mortality.
$\mathrm{hazard} \left( {\rm age} \right) = ae^{bx}$
This is a special case of Makeham's law and will Makeham
model where c=0
.
Default args:
a = 0.0002
b = 0.13
MortalityTables.InverseGompertz
— TypeInverseGompertz(;a,b,c)
Construct a mortality model following InverseGompertz's law.
\[\begin{aligned} \mathrm{hazard} \left( {\rm age} \right) &= \frac{1}{\sigma}e^\frac{age-m}{\sigma}/e^{e^\frac{-(age-m)}{\sigma}-1}`` \\ \mathrm{survival} \left( {\rm age} \right) &= \frac{1 - e^{ - e^{\frac{ - \left( {\rm age} - m \right)}{\sigma}}}}{1 - e^{ - e^{\frac{m}{\sigma}}}}`` \end{aligned}\]
Default args:
m = 49
σ = 7.7
MortalityTables.Opperman
— TypeOpperman(;a,b,c)
Construct a mortality model following Opperman's law of mortality.
$\mathrm{hazard} \left( {\rm age} \right) = \frac{a}{\sqrt{age}} + b +c\sqrt[3]{age}$
Default args:
a = 0.04
b = 0.0004
c = 0.001
MortalityTables.Thiele
— TypeThiele(;a,b,c,d,e,f,g)
Construct a mortality model following Opperman's law of mortality.
\[\begin{aligned} \mu_1 &= a \cdot e^{\left( - b \right) \cdot {\rm age}} \\ \mu_2 &= c \cdot e^{-0.5 \cdot d \cdot \left( {\rm age} - e \right)^{2}} \\ \mu_3 &= f \cdot e^{g \cdot {\rm age}} \\ \mathrm{hazard} \left( {\rm age} \right) &= \begin{cases} \mu_1 + \mu_3 & \text{if } \left( {\rm age} = 0 \right)\\ \mu_1 + \mu_2 + \mu_3 & \text{otherwise} \end{cases} \end{aligned}\]
Default args:
a = 0.02474
b = 0.3
c = 0.004
d = 0.5
e = 25
f = 0.0001
g = 0.13
MortalityTables.Wittstein
— TypeWittstein(;a,b,m,n)
Construct a mortality model following Wittstein's law of mortality.
$\mathrm{hazard} \left( {\rm age} \right) = \frac{1}{b} \cdot a^{ - \left( b \cdot {\rm age} \right)^{n}} + a^{ - \left( m - {\rm age} \right)^{n}}$
Default args:
a = 1.5
b = 1.
n = 0.5
m = 100
MortalityTables.Weibull
— TypeWeibull(;m,σ)
Construct a mortality model following Weibull's law of mortality.
Note that if σ > m, then the mode of the density is 0 and hx is a non-increasing function of x, while if σ < m, then the mode is greater than 0 and hx is an increasing function.
m >0
is a measure of locationσ >0
is measure of dispersion
\[\begin{aligned} \mathrm{hazard} \left( {\rm age} \right) = \frac{1}{\sigma} \cdot \left( \frac{{\rm age}}{m} \right)^{\frac{m}{\sigma} - 1} \\ \mathrm{cumhazard} \left( {\rm age} \right) = \left( \frac{{\rm age}}{m} \right)^{\frac{m}{\sigma}} \\ \mathrm{survival} \left( {\rm age} \right) = e^{ - \mathrm{cumhazard} \left( m, {\rm age} \right)} \end{aligned}\]
Default args:
m = 1
σ = 2
MortalityTables.InverseWeibull
— TypeInverseWeibull(;m,σ)
Construct a mortality model following Weibull's law of mortality.
The Inverse-Weibull proves useful for modelling the childhood and teenage years, because the logarithm of h(x) is a concave function.
m >0
is a measure of locationσ >0
is measure of dispersion
\[\begin{aligned} \mathrm{hazard} \left( {\rm age} \right) &= \frac{\frac{1}{\sigma} \cdot \left( \frac{{\rm age}}{m} \right)^{\frac{ - m}{\sigma} - 1}}{e^{\left( \frac{{\rm age}}{m} \right)^{\frac{ - m}{\sigma}}} - 1} \\ \mathrm{cumhazard}\left( {\rm age} \right) &= - \log\left( 1 - e^{ - \left( \frac{{\rm age}}{m} \right)^{\frac{ - m}{\sigma}}} \right) \\ \mathrm{survival}\left( {\rm age} \right) &= e^{ - \mathrm{cumhazard}\left( m, {\rm age} \right)} \end{aligned}\]
Default args:
m = 5
σ = 10
MortalityTables.Perks
— TypePerks(;a,b,c,d)
Construct a mortality model following Perks' law of mortality.
$\mathrm{hazard} \left( {\rm age} \right) = \frac{a + b \cdot c^{{\rm age}}}{b \cdot c^{ - {\rm age}} + 1 + d \cdot c^{{\rm age}}}$
Default args:
a = 0.002
b = 0.13
c = 0.01
d = 0.01
MortalityTables.VanderMaen
— TypeVanderMaen(;a,b,c,i,n)
Construct a mortality model following VanderMaen's law of mortality.
$\mathrm{hazard} \left( {\rm age} \right) = a + b \cdot {\rm age} + c \cdot {\rm age}^{2} + \frac{i}{n - {\rm age}}$
Default args:
a = 0.01
b = 1
c = 0.01
i = 100
n = 200
MortalityTables.VanderMaen2
— TypeVanderMaen2(;a,b,i,n)
Construct a mortality model following VanderMaen2's law of mortality.
$\mathrm{hazard} \left( {\rm age} \right) = a + b \cdot {\rm age} + \frac{i}{n - {\rm age}}$
Default args:
a = 0.01
b = 1
i = 100
n = 200
MortalityTables.StrehlerMildvan
— TypeStrehlerMildvan(;k,v₀,b,d)
Construct a mortality model following StrehlerMildvan's law of mortality.
$\mathrm{hazard} \left( {\rm age} \right) = k \cdot e^{\frac{\left( - v_0 \right) \cdot \left( 1 - b \cdot {\rm age} \right)}{d}}$
Default args:
k = 0.01
v₀ = 2.5
b = 0.2
d = 6.0
MortalityTables.Beard
— TypeBeard(;a,b,k)
Construct a mortality model following Beard's law of mortality.
$\mathrm{hazard} \left( {\rm age} \right) = \frac{a \cdot e^{b \cdot {\rm age}}}{1 + k \cdot a \cdot e^{b \cdot {\rm age}}}$
Default args:
a = 0.002
b = 0.13
k = 1.
MortalityTables.MakehamBeard
— TypeMakehamBeard(;a,b,c,k)
Construct a mortality model following MakehamBeard's law of mortality.
$\mathrm{hazard} \left( {\rm age} \right) =\left( {\rm age} \right) = \frac{a \cdot e^{b \cdot {\rm age}}}{1 + k \cdot a \cdot e^{b \cdot {\rm age}}} + c$
Default args:
a = 0.002
b = 0.13
c = 0.01
k = 1.
MortalityTables.Quadratic
— TypeQuadratic(;a,b,c)
Construct a mortality model following Quadratic law of mortality.
$\mathrm{hazard} \left( {\rm age} \right) = a + b \cdot {\rm age} + c \cdot {\rm age}^{2}$
Default args:
a = 0.01
b = 1.
c = 0.01
MortalityTables.GammaGompertz
— TypeGammaGompertz(;a,b,γ)
Construct a mortality model following GammaGompertz law of mortality.
$\mathrm{hazard} \left( {\rm age} \right) = \frac{a \cdot e^{b \cdot {\rm age}}}{1 + \frac{a \cdot \gamma}{b} \cdot \left( e^{b \cdot {\rm age}} - 1 \right)}$
Default args:
a = 0.002
b = 0.13
γ = 1
MortalityTables.Siler
— TypeSiler(;a,b,c,d,e)
Construct a mortality model following Siler law of mortality.
$\mathrm{hazard} \left( {\rm age} \right) = a \cdot e^{\left( - b \right) \cdot {\rm age}} + c + d \cdot e^{e \cdot {\rm age}}$
Default args:
a = 0.0002
b = 0.13
c = 0.001
d = 0.001
e = 0.013
MortalityTables.HeligmanPollard
— TypeHeligmanPollard(;a,b,c,d,e,f,g,h)
Construct a mortality model following HeligmanPollard law of mortality with 8 parameters.
$\mathrm{hazard} \left( {\rm age} \right) = a \cdot e^{\left( - b \right) \cdot {\rm age}} + c + d \cdot e^{e \cdot {\rm age}}$
Default args:
a = 0.0002
b = 0.13
c = 0.001
d = 0.001
e = 0.013
MortalityTables.HeligmanPollard2
— TypeHeligmanPollard2(;a,b,c,d,e,f,g,h)
Construct a mortality model following HeligmanPollard (alternate) law of mortality with 8 parameters.
\[\begin{aligned} \mu_1 &= a^{\left( {\rm age} + b \right)^{c}} + \frac{g \cdot h^{{\rm age}}}{1 + g \cdot h^{{\rm age}}} \\ \mu_2 &= d \cdot e^{\left( - e \right) \cdot \left( \log\left( \frac{{\rm age}}{f} \right) \right)^{2}} \\ \mathrm{hazard}\left( {\rm age} \right) &= \begin{cases} \mu_1 & \text{if } \left( {\rm age} = 0 \right)\\ \mu_1 + \mu_2 & \text{otherwise} \end{cases} \end{aligned}\]
Default args:
a = .0005
b = .004
c = .08
d = .001
e = 10
f = 17
g = .00005
h = 1.1
MortalityTables.HeligmanPollard3
— TypeHeligmanPollard3(;a,b,c,d,e,f,g,h,k)
Construct a mortality model following HeligmanPollard (alternate) law of mortality with 9 parameters.
\[\begin{aligned} \mu_1 &= a^{\left( {\rm age} + b \right)^{c}} + \frac{g \cdot h^{{\rm age}}}{1 + k \cdot g \cdot h^{{\rm age}}} \\ \mu_2 &= d \cdot e^{\left( - e \right) \cdot \left( \log\left( \frac{{\rm age}}{f} \right) \right)^{2}} \\ \mathrm{hazard}\left( {\rm age} \right) &= \begin{cases} \mu_1 & \text{if } \left( {\rm age} = 0 \right)\\ \mu_1 + \mu_2 & \text{otherwise} \end{cases} \end{aligned}\]
Default args:
a = .0005
b = .004
c = .08
d = .001
e = 10
f = 17
g = .00005
h = 1.1
k= 1.
MortalityTables.HeligmanPollard4
— TypeHeligmanPollard4(;a,b,c,d,e,f,g,h,k)
Construct a mortality model following HeligmanPollard (alternate) law of mortality with 9 parameters.
\[\begin{aligned} \mu_1 &= a^{\left( {\rm age} + b \right)^{c}} + \frac{g \cdot h^{{\rm age}^{k}}}{1 + g \cdot h^{{\rm age}^{k}}} \\ \mu_2 &= d \cdot e^{\left( - e \right) \cdot \left( \log\left( \frac{{\rm age}}{f} \right) \right)^{2}} \\ \mathrm{hazard}\left( {\rm age} \right) &= \begin{cases} \mu_1 & \text{if } \left( {\rm age} = 0 \right)\\ \mu_1 + \mu_2 & \text{otherwise} \end{cases} \end{aligned}\]
Default args:
a = .0005
b = .004
c = .08
d = .001
e = 10
f = 17
g = .00005
h = 1.1
k= 1.
MortalityTables.RogersPlanck
— TypeRogersPlanck(;a₀, a₁, a₂, a₃, a, b, c, d, u)
Construct a mortality model following RogersPlanck law of mortality.
$\mathrm{hazard}\left( {\rm age} \right) = a_0 + a_1 \cdot e^{\left( - a \right) \cdot {\rm age}} + a_2 \cdot e^{b \cdot \left( {\rm age} - u \right) - e^{\left( - c \right) \cdot \left( {\rm age} - u \right)}} + a_3 \cdot e^{d \cdot {\rm age}}$
Default args:
a₀ = 0.0001
a₁ = 0.02
a₂ = 0.001
a₃ = 0.0001
a = 2.
b = 0.001
c = 100.
d = 0.1
u = 0.33
MortalityTables.Martinelle
— TypeMartinelle(;a,b,c,d,k)
Construct a mortality model following Martinelle's law of mortality.
$\mathrm{hazard}\left( {\rm age} \right) = \frac{a \cdot e^{b \cdot {\rm age}} + c}{1 + d \cdot e^{b \cdot {\rm age}}} + k \cdot e^{b \cdot {\rm age}}$
Default args:
a = 0.001
b = 0.13
c = 0.001
d = 0.1
k = 0.001
MortalityTables.Kostaki
— TypeKostaki(;a,b,c,d,e1,e2,f,g,h)
Construct a mortality model following Kostaki's law of mortality. A nine-parameter adaptation of HeligmanPollard
.
\[\begin{aligned} \mu_1 &= a^{\left( {\rm age} + b \right)^{c}} + g \cdot h^{{\rm age}} \\ \mu_2 &= \begin{cases} d \cdot e^{ - \left( e1 \cdot \log\left( \frac{{\rm age}}{f} \right) \right)^{2}} & \text{if } \left( {\rm age} \leq f \right)\\ d \cdot e^{ - \left( e2 \cdot \log\left( \frac{{\rm age}}{f} \right) \right)^{2}} & \text{otherwise} \end{cases} \\ \eta &= \begin{cases} \mu_1 & \text{if } \left( {\rm age} = 0 \right)\\ \mu_1 + \mu_2 & \text{otherwise} \end{cases} \\ \mathrm{hazard}\left( {\rm age} \right) &= \frac{\eta}{1 + \eta} \end{aligned}\]
Default args:
a = 0.0005
b = 0.01
c = 0.10
d = 0.001
e1 = 3.
e2 = 0.1
f = 25.
g = .00005
h = 1.1
Kostaki, A. (1992). A nine‐parameter version of the Heligman‐Pollard formula. Mathematical Population Studies, 3(4), 277–288. doi:10.1080/08898489209525346
MortalityTables.Kannisto
— TypeKannisto(;a,b)
Construct a mortality model following Kannisto's law of mortality.
\[\begin{aligned} \mathrm{hazard}\left( {\rm age} \right) &= \frac{a \cdot e^{b \cdot {\rm age}}}{1 + a \cdot e^{b \cdot {\rm age}}} \\ \mathrm{cumhazard}\left( {\rm age} \right) &= 1/a * log((1 + b*exp(b*age)) / (1 + a)) \\ \mathrm{survival}\left( {\rm age} \right) &= e^{ - \mathrm{cumhazard}\left( m, {\rm age} \right)} \end{aligned}\]
Default args:
a = 0.5
b = 0.13
MortalityTables.KannistoMakeham
— TypeKannistoMakeham(;a,b,c)
Construct a mortality model following KannistoMakeham's law of mortality.
$\mathrm{hazard}\left( {\rm age} \right) = \frac{a \cdot e^{b \cdot {\rm age}}}{1 + a \cdot e^{b \cdot {\rm age}}} + c$
Default args:
a = 0.5
b = 0.13
c = 0.001