talks/2021-10-12_rstudio-inside-look/02_gapminder-ggplot2-imgur.R

library(gapminder)
library(ggplot2)

ggplot(subset(gapminder, continent != "Oceania"),
       aes(x = year, y = lifeExp, group = country, color = country)) +
  geom_line(lwd = 1, show.legend = FALSE) + facet_wrap(~ continent) +
  scale_color_manual(values = country_colors) +
  theme_bw() + theme(strip.text = element_text(size = rel(1.1)))
jennybc/reprex documentation built on Jan. 12, 2024, 9:33 p.m.