knitr::opts_chunk$set( collapse = TRUE, comment = "#>", message=FALSE, warning=FALSE )
library(CanCovidData) library(dplyr) library(ggplot2)
case_data <- get_cansim_case_data() ggplot(case_data,aes(x=`Age group`,fill=Gender)) + geom_bar() + labs(title=paste0("Cases with age or sex information as of ", max(case_data$Date2), " (n=",scales::comma(nrow(case_data)),")"), y="Number of cases", caption="Data: StatCan table 13-10-0766") + coord_flip()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.