Learn R Programming

diseasemapping (version 2.0.6)

getStdRate: Calculate the standardized rate

Description

A function to calculate the standard rate according to the Canadian standard population data set from year 1991.

Usage

getStdRate(relativeRate, model, referencePopulation, scale = 1e+05)

Value

numeric value, incidence rate in reference population.

Arguments

relativeRate

the relative cancer rate calculated by glmmBUGS of different sex and age group of people from ontario .

model

Model to standardize to, either glm model output or a vector of rates by age and sex group

referencePopulation

population to standardize to

scale

compute the expected rate per `scale' number of people.

Author

Lutong Zhou

Examples

Run this code
data(kentucky)
kentucky = terra::unwrap(kentucky)

kentucky2 = getSMR(kentucky, larynxRates, larynx, 
		regionCode="County")

data(referencepop)
newpop <- getStdRate(kentucky2$SMR, larynxRates, referencepop, scale=100000)

newpop[1:10]

Run the code above in your browser using DataLab