---
title: "Chapter 05 Template"
author: "Roger Beecham"
format: html
---

## Introduction

Reopen your project and save this `.qmd` file in the top-level folder. When working through the materials from this chapter run each code chunk separately by clicking the small green arrow beside each code chunk. By default I have set `eval: false` on most code chunks, so when you knit the code chunk will not execute.

The technical element involves analysing 2011 Census travel-to-work data.

## Setup

The code block below points to the packages you need. Uncomment the `intall_packages("devtools")` line if you have not already downloaded it. You need this for installing development versions of `gridmappr` and `odvis`. Also the ggplot2 extension package `ggforce`.

```{r}
#| echo: true
#| eval: false
library(tidyverse)
library(here)
library(sf)
# install.packages("devtools")
# install.packages("ggforce")
```

Bring in the London travel to work data.

```{r}
#| echo: true
#| eval: false
url <- "https://vis4sds.github.io/data/ch5/london_ttw.csv"
download.file(url, here("data", "london_ttw.csv"))
od_pairs <- read_csv(here("data", "london_ttw.csv"))
```
