Assignment 5: Multi-panel Figures
Description
This assignment is to gain practice creating multi-panel figures. It is due March 12.
Document Setup
For this assignment, create an HTML document using Quarto. You can refer to the homepage.qmd document we created in class for some ideas.
- Make sure your YAML header has:
- The option
embed-resources: true- This goes under the html: format option.
- It will make sure the HTML file stands alone, rather than referring to an external figure. I won’t be able to see your figure if you upload and HTML file without this option.
- The option
- I want to see the code chunks that create your figure, so make sure you use
#| echo: truein your R code chunk.- You may use code folding (
#| code-fold: true) if you’d like.
- You may use code folding (
Instructions
- Find a dataset.
- Write a small amount of narrative in your Quarto document about the dataset and why you want to make a particular visualization. Don’t spend a lot of time on the narrative.
- Create a multi-panel figure either by:
- Using base R
par()orlayout()to arrange the panels, or - Using
patchworkto arrangeggplot2panels.
I.e., don’t just use ggplot2::facet_*() to create panels.
Let me know if you have any questions!