Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

tfr

Compute total fertility rate from fertility rates


Description

Compute total fertility rates from age-specific fertility rates contained in a demogdata object.

Usage

tfr(data, PI = FALSE, nsim = 500, ...)

Arguments

data

Demogdata object of type "fertility" such as obtained from read.demogdata, forecast.fdm.

PI

If TRUE, produce a prediction interval.

nsim

Number of simulations to use when computing a prediction interval.

...

Other arguments passed to simulate when producing prediction intervals.

Value

If data are of class demogdata, the function returns a time series of fertility rates. If data are from forecast.fdm, the function returns an object of class forecast containing point forecasts and (optionally) prediction intervals.

Author(s)

Rob J Hyndman

See Also

Examples

plot(tfr(aus.fert))
ausfert.fcast <- forecast(fdm(aus.fert))
plot(tfr(ausfert.fcast,PI=TRUE,nsim=400))

demography

Forecasting Mortality, Fertility, Migration and Population Data

v1.22
GPL (>= 2)
Authors
Rob J Hyndman with contributions from Heather Booth, Leonie Tickle and John Maindonald.
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.