#Sample Solution
---
title: "Joining Tables in R"
output: html_notebook
---
```{r message = FALSE}
# load packages
library(readr)
library(dplyr)
```
```{r message = FALSE}
# load store_a and store_b data
store_a <- read_csv("store_a.csv")
store_b <- read_csv("store_b.csv")
```
```{r}
# inspect store_a and store_b
head(store_a)
head(store_b)
```
```{r}
# define left_a_b here:
left_a_b <- store_a %>% left_join(store_b)
left_a_b
```
```{r}
# define left_b_a here:
left_b_a <- store_b %>% left_join(store_a)
left_b_a
```
No comments:
Post a Comment