Skip to contents

Returns the Akaike information criterion of a "MortalityLaw" fit, 2 * k - 2 * logLik, with \(k\) the number of fitted parameters. Like the log-likelihood it is defined only for the likelihood-based objectives and is NaN otherwise. Use it to compare candidate laws fitted to the same data.

Usage

# S3 method for class 'MortalityLaw'
AIC(object, ...)

Arguments

object

An object of class "MortalityLaw".

...

Further arguments passed to or from other methods.

Value

The AIC value for a single fit, or a named vector of AIC values for a multiple fit.

Examples

x  <- 45:75
M1 <- MortalityLaw(x = x, Dx = ahmd$Dx[as.character(x), "1950"],
                   Ex = ahmd$Ex[as.character(x), "1950"],
                   law = "makeham", opt.method = "poissonL")
AIC(M1)
#>     AIC 
#> 1156965