# NOT RUN {
df <- download_google_cmr_data(silent = TRUE, cached = TRUE)
df %>%
dplyr::group_by(date) %>%
dplyr::summarize(
retail_recreation = mean(retail_recreation, na.rm = TRUE)
) %>%
ggplot2::ggplot(ggplot2::aes(x = date, y = retail_recreation)) +
ggplot2::geom_line()
df <- download_google_cmr_data(type = "country_region", silent = TRUE, cached = TRUE)
df %>%
dplyr::filter(iso3c == "USA") %>%
dplyr::select(-iso3c) %>%
dplyr::group_by(region) %>%
dplyr::summarise(`Retail and Recreation Effect` =
max(retail_recreation, na.rm = TRUE) -
min(retail_recreation, na.rm = TRUE)) %>%
dplyr::rename(`U.S. State` = region) %>%
dplyr::arrange(-`Retail and Recreation Effect`)
# }
Run the code above in your browser using DataLab