make.demogdata: Make demogdata objects for particular states and years.

Description Usage Arguments Value Author(s) References Examples

View source: R/make.demogdata.R

Description

The function make.demogdata will return a demogdata object for the given state and years.

Usage

1
2
3
make.demogdata(state = c("AUS", "ACT", "NSW", "NT", "QLD", "SA", "TAS", "VIC",
  "WA"), year = 2001:2010, combineyears = FALSE, upper.age = 100,
  smooth = TRUE, population = c("cohort", "interpolated", "backcast"))

Arguments

state

Character code indicating state or territory of Australia, or "AUS" indicating the whole of Australia.

year

Years to include in the demogdata object. The default is to include all available years from the ideaths database.

combineyears

Logical value indicating whether deaths and population numbers should be combined across years. Default is FALSE.

upper.age

Upper age group, by default set to 100+.

smooth

Logical value indicating whether mortality rates should be smoothed using penalized regression splines. Default is TRUE.

population

Character code indicating which estimated residential indigenous population should be used. "cohort" means use the ERP obtained by linearly interpolating the 2001, 2006 and 2011 census figures along cohorts. "interpolated" means use the ERP obtained by linearly interpolating the 2001, 2006 and 2011 census figures along ages. "backcast" means use the ABS ERP based on 2011 census values.

Value

A demogdata object containing mortality rates for males, females and total. See demogdata for more information about demogdata objects.

Author(s)

Rob J Hyndman <Rob.Hyndman@monash.edu>

References

Choi, C., Hyndman, R.J., Smith, L., and Zhao, K. (2010) An enhanced mortality database for estimating indigenous life expectancy. Report for Australian Institute of Health and Welfare.

Examples

1
2
3
4
5
6
7
8
nsw <- make.demogdata(state="NSW")
plot(nsw, "female")

# Show smoothing
test <- make.demogdata(state="NSW", smooth=FALSE)
test.sm <- demography::smooth.demogdata(test)
plot(test, series='female', year=2006, type="p", pch=1)
lines(test.sm, series='female', year=2006, col="red")

robjhyndman/indmortality documentation built on May 20, 2019, 6:48 p.m.