# Part 1

### 1.1

Load all the libraries we will use in this lab. 

```{r}
library(readr)
library(tidyverse)
library(dplyr)
library(lubridate)
library(jhur)
```

Create some data to work with by running the following code chunk.

```{r}
set.seed(1234)

int_vect <- rep(seq(from = 1, to = 10), times = 3)
rand_vect <- sample(x = 1:30, size = 30, replace = TRUE)
TF_vect <- rep(c(TRUE, TRUE, FALSE), times = 10)
TF_vect2 <- rep(c("TRUE", "TRUE", "FALSE"), times = 10)
```

### 1.2

Determine the class of each of these new objects.

```{r 1.2response}

```

### 1.3

Are `TF_vect` and `TF_vect2` different classes? Why or why not?

```{r 1.3response}

```

### 1.4

Create a tibble combining these vectors together called `vect_data` using the following code.

```{r}
vect_data <- tibble(int_vect, rand_vect, TF_vect, TF_vect2)
```

### 1.5

Coerce `rand_vect` to character class using `as.character()`. Save this vector as `rand_char_vect`. How is the output for `rand_vect` and `rand_char_vect` different?

```{r 1.5response}

```

### 1.6

Read in the Charm City Circulator data using `read_circulator()` function from `jhur` package using the code supplied in the chunk. Or alternatively using the url link.

```{r}
circ <- read_circulator()
circ <- read_csv(file = "http://jhudatascience.org/intro_to_r/data/Charm_City_Circulator_Ridership.csv")
```

Use the `str()` function to take a look at the data and learn about the column types.

```{r 1.6response}

```

### 1.7

Use the `mutate()` function to create a new column named `date_formatted` that is of `Date` class. The new variable is created from `date` column. Hint: use `mdy()` function. Reassign to `circ`.

```
# General format
NEWDATA <- OLD_DATA %>% mutate(NEW_COLUMN = OLD_COLUMN)
```

```{r 7response}

```


# Practice on Your Own!

### P.1

Move the `date_formatted` variable to be before `date` using the `relocate` function. Take a look at the data using `glimpse()`. Note the difference between `date` and `date_formatted` columns.

```
# General format
NEWDATA <- OLD_DATA %>% relocate(COLUMN1, .before = COLUMN2)
```

```{r P.1response}

```

### P.2

Use `range()` function on `date_formatted` variable to display the range of dates in the data set. How does this compare to that of `date`? Why? (Hint: use the pull function first to pull the values.)

```{r P.2response}

```
