R package implementing actuarial mortality tables (period and cohort life tables)
The MortalityTables package provides the
mortalityTable base class and some derived classes to handle different types of mortality tables (also called life tables), mainly used for life insurance. Additionally it provides a plot function to compare multiple life tables either directly using the absolute mortalities in log-linear plots or using relative mortalities as percentages of a given reference table.
Provided types of mortality tables are:
mortalityTable.period (ages, deathProbs, ..., baseYear=2000)
baseYear + nis calculated as:
YOBcan be calculated as
The package provides several real-life life tables published by census bureaus and actuarial associations around the world. You can use the function
mortalityTables.list to list all available datasets (if no argument is given) or all datasets that match the given pattern (wildcard character is *). You can then use
mortalityTables.load to load either one single data set or all datasets that match the pattern.
# list all available data sets mortalityTables.list() # list all datasets for Austria mortalityTables.list("Austria_*") # Load the German annuity table DAV 2004-R mortalityTables.load("Germany_Annuities_DAV2004R") # Load all Austrian data sets mortalityTables.load("Austria_*")
For further information on how to use the package, see the “Using the MortalityTables Package” vignette.