Feel free to try the exercises below at your leisure. Solutions will
be posted later in the week!
Data Scraping
- Using
rvest::html_table, scrape the table of City
Council members in Washington D.C. from Wikipedia
- Using the inspector gadget or similar tool, web scrape two pages of
Climate Change news articles titles and links from Politico.
Working with APIs
- Register
for an API key with the U.S. Census Bureau. Once it is received,
download any data point of interest from the American Community Survey
or Decennial Census. (Documentation
here)
- Try to replicate #1 using the
tidycensus
package, which is an API wrapper.