who-mortality: Use WHO Mortality Rate

Description Usage Arguments Details Value Examples

Description

Returns age and sex-specific mortality probabilities for a given country.

Usage

1
2
3
4
5
get_who_mr_memo(age, sex = NULL, region = NULL, country = NULL,
  year = "latest", local = FALSE)

get_who_mr(age, sex = NULL, region = NULL, country = NULL,
  year = "latest", local = FALSE)

Arguments

age

age as a continuous variable.

sex

sex as "FMLE"-"MLE", 0-1 (male = 0, female = 1) or 1-2 (male = 1, female = 2).

region

Region code. Assumed NULL if provided along with country.

country

Country code (see details).

year

Use data from that year. Defaults to "latest".

local

Fetch mortality data from package cached data?

Details

Locally cached data is used in case of connection problems, of if local = TRUE. For memory space reasons local data is only available for WHO high-income countries, and only for the latest year.

The results of get_who_mr are memoised for options("heemod.memotime") (default: 1 hour) to increase resampling performance.

Value

This function should be used within define_transition() or define_parameters().

Examples

1
2
3
4
define_transition(
  C, get_who_mr(age = 50 + markov_cycle, sex = "FMLE", country = "FRA"),
  0, 1
)


Search within the heemod package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.