mT.extrapolateTrendExp: Extrapolate a mortality trend exponentially

View source: R/utilityFunctions.R

mT.extrapolateTrendExpR Documentation

Extrapolate a mortality trend exponentially

Description

Extrapolate a mortality trend in a mortalityTable object using an exponential function (i.e. the trend decreases towards 0 exponentially). This is mainly used to extrapolate an observed age-specific trend to very old ages. Existing trend function values above (or below, respectively) the idx are overwritten.

Usage

mT.extrapolateTrendExp(table, idx, up = TRUE)

Arguments

table

A life table object (instance of a mortalityTable class) or a list, table or array of mortalityTable objects

idx

Index (typically age) of the position of the fit

up

Whether the fit is forward- or backward-facing (i.e. to old or young ages)

Examples

mortalityTables.load("Austria_Annuities_AVOe2005R")
# extrapolate the trend exponentially from age 95 instead (overwriting the existing trend)
avoe2005exp = mT.extrapolateTrendExp(AVOe2005R.male, 95)
plotMortalityTrend(mT.setName(avoe2005exp, "AVĂ– 2005R with trend extrapolated from age 85 up"),
                   AVOe2005R.male, Period = 2020, ages = 60:120)

MortalityTables documentation built on Nov. 2, 2023, 5:52 p.m.