pkgs <- c(
"tidyverse", "gapminder", "scales", "glue", "ggtext",
"showtext", "sysfonts", "ragg", "camcorder", "RColorBrewer",
"MetBrewer", "viridis", "ggh4x", "ggrepel", "ggforce",
"patchwork", "cowplot"
)
install.packages(setdiff(pkgs, rownames(installed.packages())))You already know the ggplot2 basics - now it is time to take full control of your plots. This section covers axis customization, color palettes, theme design, export, advanced plot types, facetting, and useful extension packages.
Prerequisites: Before diving in, you should be comfortable with the content from First ggplot and Factors.
NoteRequired R packages
The chapters in this section use the R packages below. Run this once to install any that are missing: