Title: Social Contact Matrices for 177 Countries
Version: 1.1.0
Description: Data package for the supplementary data in Prem et al. (2017) <doi:10.1371/journal.pcbi.1005697> and Prem et al. <doi:10.1371/journal.pcbi.1009098>. Provides easy access to contact data for 177 countries, for use in epidemiological, demographic or social sciences research.
License: MIT + file LICENSE
Depends: R (≥ 3.5.0)
Suggests: countrycode, ggplot2, knitr, rmarkdown, spelling, testthat(≥ 3.0.0), covr
URL: https://hugogruson.fr/contactdata/, https://github.com/bisaloo/contactdata
BugReports: https://github.com/bisaloo/contactdata/issues
Encoding: UTF-8
Language: en-GB
RoxygenNote: 7.3.2
VignetteBuilder: knitr
Config/testthat/edition: 3
NeedsCompilation: no
Packaged: 2024-09-25 14:56:20 UTC; hugo
Author: Hugo Gruson ORCID iD [cre, aut, cph], Kiesha Prem ORCID iD [dtc], Alex Richard Cook ORCID iD [dtc], Mark Jit ORCID iD [dtc]
Maintainer: Hugo Gruson <hugo.gruson+R@normalesup.org>
Repository: CRAN
Date/Publication: 2024-09-25 17:20:06 UTC

contactdata: Social Contact Matrices for 177 Countries

Description

logo

Data package for the supplementary data in Prem et al. (2017) doi:10.1371/journal.pcbi.1005697 and Prem et al. doi:10.1371/journal.pcbi.1009098. Provides easy access to contact data for 177 countries, for use in epidemiological, demographic or social sciences research.

Author(s)

Maintainer: Hugo Gruson hugo.gruson+R@normalesup.org (ORCID) [copyright holder]

Other contributors:

See Also

Useful links:


Get a data.frame (in long format) of population by age for multiple countries

Description

Get a data.frame (in long format) of population by age for multiple countries

Usage

age_df_countries(countries)

Arguments

countries

A character string or a vector of character containing the names of the countries for which to return contact data

Value

A data.frame (in long format) with 3 columns:

References

https://www.census.gov/programs-surveys/international-programs/about/idb.html

Examples

age_df_countries(c("Austria", "Belgium"))


Get a data.frame (in long format) of contact data for multiple countries

Description

Get a data.frame (in long format) of contact data for multiple countries

Usage

contact_df_countries(countries, ...)

Arguments

countries

A character string or a vector of character containing the names of the countries for which to return contact data

...

Arguments passed to contact_matrix()

Value

A data.frame (in long format) with 4 columns:

References

Kiesha Prem, Alex R. Cook, Mark Jit, Projecting social contact matrices in 152 countries using contact surveys and demographic data, PLoS Comp. Biol. (2017), doi:10.1371/journal.pcbi.1005697

Kiesha Prem, Kevin van Zandvoort, Petra Klepac, Rosalind M. Eggo, Nicholas G. Davies, CMMID COVID-19 Working Group, Alex R. Cook, Mark Jit, Projecting contact matrices in 177 geographical regions: An update and comparison with empirical data for the COVID-19 era, PLoS Comp. Biol. (2021), doi:10.1371/journal.pcbi.1009098.

Examples

contact_df_countries(c("Austria", "Belgium"), location = "all")


Get contact data matrix for a specific country

Description

Get contact data matrix for a specific country

Usage

contact_matrix(
  country,
  location = c("all", "home", "school", "work", "other"),
  geographic_setting = c("all", "rural", "urban"),
  data_source = c("2020", "2017")
)

Arguments

country

Character. The name of the country for which you want contact data.

location

Character. One of "all" (default), "home", "school", "work" or "other".

geographic_setting

Character. One of "all" (default), "rural", "urban"

data_source

Character. Either "202O" (default) or "2017"

Value

A square (16 by 16) matrix containing the contact data between the different age classes for a given country.

References

Kiesha Prem, Alex R. Cook, Mark Jit, Projecting social contact matrices in 152 countries using contact surveys and demographic data, PLoS Comp. Biol. (2017), doi:10.1371/journal.pcbi.1005697

Kiesha Prem, Kevin van Zandvoort, Petra Klepac, Rosalind M. Eggo, Nicholas G. Davies, CMMID COVID-19 Working Group, Alex R. Cook, Mark Jit, Projecting contact matrices in 177 geographical regions: An update and comparison with empirical data for the COVID-19 era, PLoS Comp. Biol. (2021), doi:10.1371/journal.pcbi.1009098.

Examples

contact_matrix("France", location = "all")

contact_matrix("Belgium", location = "school")


Get the list of countries included in the dataset

Description

Get the list of countries included in the dataset

Usage

list_countries(
  geographic_setting = c("all", "rural", "urban"),
  data_source = c("2020", "2017")
)

Arguments

geographic_setting

Character. One of "all" (default), "rural", "urban"

data_source

Character. Either "202O" (default) or "2017"

Value

A character vector with the name of all countries included in the dataset

Note

This package uses the nomenclature from the countrycode package. If your names differ from the names used here, you should use countrycode as well to update them.

References

Kiesha Prem, Alex R. Cook, Mark Jit, Projecting social contact matrices in 152 countries using contact surveys and demographic data, PLoS Comp. Biol. (2017), doi:10.1371/journal.pcbi.1005697

Kiesha Prem, Kevin van Zandvoort, Petra Klepac, Rosalind M. Eggo, Nicholas G. Davies, CMMID COVID-19 Working Group, Alex R. Cook, Mark Jit, Projecting contact matrices in 177 geographical regions: An update and comparison with empirical data for the COVID-19 era, PLoS Comp. Biol. (2021), doi:10.1371/journal.pcbi.1009098.

Examples

list_countries()