powered by
Draws a Heat Map based on the life expectancy of a fitted BLC or PredBLC model.
# S3 method for BLC Heatmap(x, x_lab = NULL, age = NULL, color = c("red", "white", "blue"), ...)
A ggplot2 heatmap of the life expectancy.
A BLC or PredBLC object, result of a call to blc() function or forecast via predict() function.
BLC
PredBLC
Description of the modelled object.
Vector with the ages to plot the heatmap.
Vector of colours used in the heatmap.
Further arguments passed to or from other methods.
Heatmap.HP() and Heatmap.DLM() for HP or DLM methods.
Heatmap.HP()
Heatmap.DLM()
HP
DLM
## Importing log-mortality data from Portugal: data(PT) Y <- PT ## Fitting the model fit = blc(Y = Y, M = 100, bn = 20) ## Heatmap: Heatmap(fit, x_lab = 2000:2015, age = 18:80)
Run the code above in your browser using DataLab