if (require(tidyr) && require(ggplot2)) {
bsflu |>
gather(variable,value,-date,-day) |>
ggplot(aes(x=date,y=value,color=variable))+
geom_line()+
labs(y="number of boys",title="boarding school flu outbreak")+
theme_bw()
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.