knitr::opts_chunk$set( collapse = TRUE, comment = "#>", fig.path = "man/figures/README-", out.width = "100%" )
A selection of Government of Ontario press releases scraped from the Ontario Newsroom. This information is © Queen's Printer for Ontario, 2020, and is to be used for teaching and research.
You can install the development version from GitHub with:
# install.packages("devtools") devtools::install_github("chris31415926535/ogreleases")
This example shows how to load the data, count the number of press releases from each source, and plot the results:
library(tidyverse) library(ogreleases) ## load the data df <- ogreleases::ogreleases_data # who issued the most press releases? df %>% group_by(issuer) %>% summarise(count=n()) %>% ggplot() + geom_col(aes(x=reorder(issuer, count), y=count)) + coord_flip() + theme_minimal() + labs( title="Press Releases by Source, Jan 2019 - Sept 2020", x=NULL, y = NULL )
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.