Skip to content

Commit f09c9af

Browse files
authored
Merge pull request #688 from jhudsl/images-added
Added Allison Horst's awesome illustrations
2 parents 975d4b7 + 307198c commit f09c9af

File tree

4 files changed

+14
-0
lines changed

4 files changed

+14
-0
lines changed

modules/Data_Visualization/Data_Visualization.Rmd

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,12 @@ Slide Credit: Tanya Shapiro
112112

113113
- [ggplot2 gallery](https://www.r-graph-gallery.com/ggplot2-package.html)
114114

115+
```{r, fig.alt="ggplot with cartoon artists assembling works of art.", out.width = "40%", echo = FALSE, fig.show='hold',fig.align='center'}
116+
knitr::include_graphics("img/ggplot2_masterpiece.jpeg")
117+
```
118+
119+
Artwork by @allison_horst. https://allisonhorst.com/
120+
115121
## Tidy data
116122

117123
To make graphics using `ggplot2`, our data needs to be in a **tidy** format
Loading

modules/Manipulating_Data_in_R/Manipulating_Data_in_R.Rmd

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -279,6 +279,14 @@ wide <- long %>% pivot_wider(names_from = "name",
279279
wide
280280
```
281281

282+
## `gather()` and `spread()`
283+
284+
```{r, fig.alt="Gather and spread functions in cartoon form.", out.width = "50%", echo = FALSE, align = "center"}
285+
knitr::include_graphics("images/gatherspread.jpeg")
286+
```
287+
288+
Artwork by @allison_horst. https://allisonhorst.com/
289+
282290
## Summary
283291

284292
- `tidyr` package (part of `tidyverse`) helps us convert between wide and long data
Loading

0 commit comments

Comments
 (0)