pop.pred: Population forecasting

Description Usage Arguments Details Value Author(s) Examples

View source: R/pop.pred.R

Description

Population forecasting using mortality forecast and simple time series forecast for age 0 population

Usage

1
pop.pred(mort, mort.fcast)

Arguments

mort

mortality data of class 'demogdata'

mort.fcast

mortality forecast of class 'fmforecast'

Details

ARIMA(0,2,2)-model is used to forecast age 0 populaton.

Value

population forecast of class 'demogdata'

Author(s)

Arto Luoma <arto.luoma@wippies.com>

Examples

1
2
3
4
5
6
7
data(fin)
data(fin.fcast)
fin.pcast <- pop.pred(fin,fin.fcast)
plot(fin,plot.type="functions",series="total",transform=FALSE,
     datatype="pop",ages=c(0:100), years=c(1990+0:5*10), xlab="Age")
lines(fin.pcast,plot.type="functions",series="total",transform=FALSE, 
      datatype="pop",ages=c(0:100), years=c(1990+0:5*10), lty=2)

Example output

Loading required package: rgl
Loading required package: demography
Loading required package: forecast
This is demography 1.22 

Warning messages:
1: In rgl.init(initValue, onlyNULL) : RGL: unable to open X11 display
2: 'rgl_init' failed, running with rgl.useNULL = TRUE 
3: .onUnload failed in unloadNamespace() for 'rgl', details:
  call: fun(...)
  error: object 'rgl_quit' not found 
4: no DISPLAY variable so Tk is not available 

RcmdrPlugin.RiskDemo documentation built on April 6, 2021, 5:06 p.m.