View source: R/download_acaps_npi_data.R
download_acaps_npi_data | R Documentation |
Downloads non-pharmaceutical interventions (NPI) data related to Covid-19
from the ACAPS governmental measures database
(https://www.acaps.org/covid19-government-measures-dataset).
Since ACAPS is no longer
updating this data since December 12, 2020 historic data is
downloaded and calling the function with cache = FALSE
yields
a warning.
download_acaps_npi_data(silent = FALSE, cached = FALSE)
silent |
Whether you want the function to send some status messages to
the console. Might be informative as downloading will take some time
and thus defaults to |
cached |
Whether you want to download the cached version of the data
from the tidycovid19 Github repository instead of retrieving the
data from the authorative source. Downloading the cached version is
faster and the cache is updated daily. Defaults to |
A data frame containing the data, organized by intervention. It
includes a timestamp
variable indicating the time of data
retrieval.
df <- download_acaps_npi_data(silent = TRUE, cached = TRUE)
df %>%
dplyr::group_by(country) %>%
dplyr::summarise(number_of_interventions = dplyr::n()) %>%
dplyr::arrange(-number_of_interventions)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.