plot_weekly_deaths: Plotting the total number of weekly deaths in Germany

Description Usage Arguments Value Warning See Also Examples

View source: R/deaths.R

Description

plot_weekly_deaths is used to create a plot of the total number of deaths during the time span of a year. It is possible to include more than one year. The plot can be further specified for several age groups.

Usage

1
plot_weekly_deaths(years = 2020, age = "A80+", rate = F)

Arguments

years

A vector of years. The years must be represented as integers. Data is available for the years 2014 up to 2020.

age

A string that indicates the desired age group. Possible age groups are "A00-A34", "A35-A59", "A60-A79" and "A80+".

rate

A boolean to decide whether the absolute number of weekly deaths or the weekly mortality should be plotted.

Value

A plot of the weekly death data of the years and age groups the user specified.

Warning

Population data per age group is only available for the whole year (census is always 31-12). Thus, if rate=T, the mortality cannot be 100% precise because the weekly number of deaths is always divided by the same factor, even though the age distribution is continuously changing during the year. Due to aging society, the mortality is therefore overestimated during the first weeks of the year.

See Also

Other total number of weekly deaths: get_weekly_deaths()

Examples

1
2
3
4
5
6
7
plot_weekly_deaths(c(2014,2016,2016), age="A35-A59",rate=T)

## Not run: plot_weekly_deaths("1999")
#Data is only available for 2014-2020 and \code{years} must be an integer vector

## Not run: plot_weekly_deaths(2015,age=65)
#The age group must be a string. Allowed strings are "A00-A34","A35-A59","A60-79" and "A80+".

slausmeister/revolution documentation built on Dec. 23, 2021, 3:24 a.m.