# \donttest{
# Load the entire dataset
data_all <- getDOSE()
# Load dataset filtered by specific years
data_2018_2019 <- getDOSE(years = c(2018, 2019))
# Load dataset filtered by specific countries (using ISO3C codes)
data_usa_can <- getDOSE(countries = c('USA', 'CAN'), format_countries = 'iso3c')
# Load dataset filtered by year and countries (using country names)
data_mex_2019 <- getDOSE(years = 2019, countries = c('Mexico'),
format_countries = 'country.name')
# }
if (FALSE) {
# Store the data in a persistent cache so it is reused across sessions
data_cached <- getDOSE(cache = TRUE)
}
Run the code above in your browser using DataLab