-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathsetup.Rmd
31 lines (24 loc) · 944 Bytes
/
setup.Rmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# Setup
This section describes how the code in the book is set up.
## Packages
Here are the packages used by the code in this book. The last three are my own:
[tidyxl](https://nacnudus.github.io/tidyxl),
[unpivotr](https://nacnudus.github.io/unpivotr) and
[smungs](https://github.com/nacnudus/smungs). You will need to install the
latest versions from CRAN or GitHub.
```{r}
library(tidyverse)
library(readxl)
library(tidyxl)
library(unpivotr)
library(smungs) # GitHub only https://github.com/nacnudus/smungs
```
## Data
The examples draw from a spreadsheet of toy data, included in the
[unpivotr](https://nacnudus.github.io/unpivotr) package. It is recommended to
[download](https://github.com/nacnudus/unpivotr/raw/master/inst/extdata/worked-examples.xlsx)
the spreadsheet and have open it in a spreadsheet application while you read the
book.
```{r}
path <- system.file("extdata", "worked-examples.xlsx", package = "unpivotr")
```