Class 8 — Visualizing the Effect
Part II
Turn your HW4 summary table into a picture — build a labeled ggplot2 figure layer by layer, then adapt the code to your own data and share it in a gallery walk.
PART II · CLASS 8
Last class you turned your messy pilot file into a clean condition-level table. Today that table becomes something a reader can understand in two seconds. Working incrementally with ggplot() and aes(), you’ll build a labeled figure layer by layer on instructor sample data, try a few variations, then adapt the same code to your own HW4 summary table and share it with classmates in a gallery walk.
Reading due: R4DS ch. 1, 9 · Due today: HW4 due
What you’ll be able to do
- Map variables to visual properties using
ggplot()andaes()(x, y, and optionally fill/color), building on the tibble/column fluency from Classes 6–7. - Build a single clean, labeled figure — a boxplot or a bar chart with error bars — showing a condition-level RT (or accuracy) difference.
- Explain what a “layer” is in ggplot2’s grammar of graphics and add at least one layer beyond the base geom (labels, a second geom, or a theme).
- Adapt working plotting code to a new dataset by swapping in your own column names, applying it to your own HW4-wrangled summary table rather than instructor sample data.
- Give and receive brief, specific peer feedback on a finished data visualization.