Skip to contents

Row-normalized heatmap showing what fraction of each disease's deaths occur in each age group. Designed for Table 5 or Table 6 data.

Usage

plot_age_profile(
  data,
  disease = "Major_Group",
  age_order = c("<1", "1-4", "5-14", "15-24", "25-34", "35-44", "45-54", "55-64",
    "65-69", "70+"),
  title = NULL
)

Arguments

data

A data frame with Age_Group, a disease label column, and Deaths.

disease

Column with disease labels. Default "Major_Group".

age_order

Character vector of age groups in order. Default covers the standard MCCD groups from <1 to 70+.

title

Plot title. Default NULL.

Value

A ggplot object.