## Importing log-mortality data from Portugal:
data(PT)
Y <- PT
## Fitting the model
fit = blc(Y = Y, M = 100, bn = 20)
## Prediction for 2 years ahead
pred = predict(fit, h = 2)
## The log-mortality median for the first year of prediction
quantile(pred, q = 0.5, h = 1)
## The 0.1 and 0.9 quantiles for the first and second year of prediction
quantile(pred, q = c(0.1, 0.9), h = 1)
quantile(pred, q = c(0.1, 0.9), h = 2)
Run the code above in your browser using DataLab