We'll continue to work on the same .Rmd file from the previous exercise.    

<hr> 

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

data("BabyNames", package = "dcData")
BabyNamesSupp <- 
  read_csv("https://github.com/jbpost2/Basics-of-R-for-Data-Science-and-Statistics/raw/master/datasets/BabyNamesSupp.csv",
           col_types = cols(sex = col_character()))  # fixes `sex`
BabyNamesFull <- bind_rows(BabyNames, BabyNamesSupp)
```

# 11.1 

1. Use the data object created by the code below to create a line plot (via `geom_line()`) that looks like the one below.


```{r}
names <- c("Justin", "George", "Alexander", "Jacob", "Anderson")
lineData <- BabyNamesFull %>%
  filter(name %in% names) %>% 
  group_by(name, year) %>%
  summarise(total = sum(count))
```

```{r}
ggplot(lineData) +
 geom_line(aes(x = year, y = total, color = name)) 
```


<hr>

<br>

<a href = "https://jbpost2.github.io/Basics-of-R-for-Data-Science-and-Statistics/CourseFiles.html"><button type="button">Course Files Page</button></a>
