Skip to content

Instantly share code, notes, and snippets.

@timcdlucas
Created November 25, 2019 14:16
Show Gist options
  • Save timcdlucas/348f214e55c84055c32599ca44cfbcdc to your computer and use it in GitHub Desktop.
Save timcdlucas/348f214e55c84055c32599ca44cfbcdc to your computer and use it in GitHub Desktop.
palettes and patchwork
# devtools::install_github("thomasp85/patchwork")
library(patchwork)
library(paletteer)
library(ggplot2)
ggplot(mtcars, aes(mpg, disp, colour = factor(cyl))) +
geom_point() +
scale_colour_paletteer_d('palettetown', 'spearow') +
ggtitle('Spearow loves mtcars') +
ggplot(mtcars, aes(mpg, hp, colour = factor(cyl))) +
geom_point() +
scale_colour_paletteer_d('yarrr', 'usualsuspects') +
ggtitle('Keyser Söze loves mtcars')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment