lifetime

Future lifetimes - Computes expectations and moments of future lifetime

MIT License. Copyright (c) 2022-2023 Terence Lim

class actuarialmath.lifetime.Lifetime(**kwargs)[source]

Bases: Survival

Computes expected moments of future lifetime

e_x(x: int, s: int = 0, t: int = -999, curtate: bool = True, moment: int = 1) float[source]

Compute curtate or complete expectations and moments of life

Parameters:
  • x – age of selection

  • s – years after selection

  • t – limited at t years

  • curtate – whether curtate (True) or complete (False) expectations

  • moment – whether to compute first (1) or second (2) moment

Examples

>>> def l(x, s): return 0. if (x+s) >= 100 else 1 - ((x + s)**2) / 10000.
>>> print(Lifetime().set_survival(l=l).e_x(75, t=10, curtate=False))