if (requireNamespace("wpp2017", quietly = TRUE)) {
wpp_age("Italy", c(1990, 2000))
}
# For more recent data, use wpp2024 from GitHub:
# remotes::install_github("PPgp/wpp2024")
# library(wpp2024)
# data(popAge1dt)
# uk_pop <- popAge1dt[name == "United Kingdom" & year == 2020,
# .(lower.age.limit = age, population = pop * 1000)]
# contact_matrix(polymod, countries = "United Kingdom", survey_pop = uk_pop)
Run the code above in your browser using DataLab