---
title: "Lab 14.1 - Restaurant &amp; Health Codes"
author: "Author Goes Here"
date: "Semester Goes Here"
output:
  html_document:
    code_download: true
---

```{r include = FALSE}
knitr::opts_chunk$set(echo = TRUE)
```

```{r warning = FALSE, message = FALSE}
library(tidyverse)
```

The goal of this exercise is to visualize health code violations in New York City restaurants.

```{r}
library(mdsr)
Violations
```

🚧
Following the instructions given in Section 18.6, Problem 1, modulo the following comments.

- 1.a. Geocoding

  - The Violations dataset has nearly a half-million records, with over 25K unique addresses. Geocoding that many addresses would likely take some hours to complete, so we suggest that you focus you filter down to those addresses that had more than 75 violations (or even more while you're developing your code). 
  - Not all addresses geocode to actual coordinates, so plan to filter out any records with `NA` values for either lat or lon (nb. putting `na.omit()` into your pipeline will filter out all rows with NA values for any field.)

<br>

- 1.b. Static Mapping

  - There a number of ways to illustrate the "nature and extent" of restaurant violations. We suggest starting the raw count of violations at each address. Feel free to go beyond this as time allows.

<br>

- 1.c. Interactive Mapping

  - We leave this interactive map step as an optional extension.
