Hi! 👋 We are currently looking for help to improve the colour palettes extracted from the suffragette and sufragists banners below. Do you have an eye for colour? Create a pull request or reach out to us: @d_alburez @ValentinaIemmi.
library(devtools)
install_github("alburezg/suffrager")
library(suffrager)
See all available palettes:
names(suf_palettes)
#> [1] "london" "oxon" "CarolMan" "hanwell" "chelsea" "classic"
# Discrete
suf_palette("london")
library(ggplot2)
#> Warning: package 'ggplot2' was built under R version 3.5.2
data(airquality)
ggplot(airquality, aes(x=Day, y=Month)) +
geom_tile(aes(fill=Temp)) +
scale_fill_gradientn(colours = rev(suf_palette("london", 30, type = "continuous"))) +
coord_equal()
# Discrete
suf_palette("oxon")
data(diamonds)
ggplot(diamonds, aes(x=carat, y=price, colour=cut)) +
geom_point() +
scale_colour_manual(values = suf_palette("oxon"))
# Discrete
suf_palette("CarolMan")
data(iris)
ggplot(iris,aes(x = Petal.Length, fill = Species)) +
geom_density() +
scale_color_manual(values = suf_palette("CarolMan"))
# Discrete
suf_palette("hanwell")
data(diamonds)
ggplot(diamonds, aes(x = carat, fill = cut)) +
geom_histogram(bins = 20) +
scale_fill_manual(values = rev(suf_palette("hanwell")))
# Discrete
suf_palette("chelsea")
data("airquality")
ggplot(airquality, aes(x = factor(Month), y = Ozone, fill = factor(Month))) +
geom_violin() +
scale_fill_manual(values = suf_palette("chelsea"))
#> Warning: Removed 37 rows containing non-finite values (stat_ydensity).
# Discrete
suf_palette("classic")
data(iris)
ggplot(iris,aes(x = Petal.Length, y = Petal.Width, color = Species)) +
geom_point() +
geom_smooth(method = 'loess') +
facet_grid(. ~ Species, scales = 'free') +
scale_color_manual(values = suf_palette("classic", n = 3, type = "continuous"))
Create a continuous palette of length n
based on the suffragette colours:
# Continuous
suf_palette("classic", n = 6, type = "continuous")
Developed by Diego Alburez-Gutierrez and Valentina Iemmi. The package's architecture and documentation was taken from Karthik Ram's wesanderson package. Images for the london
, oxon
, CarolMan
, chelsea
, and classic
palettes used with kind permission from the LSE Womens Library Collection. Images for palette hanwell
were provided by the 100 Banners project and are used with the project's consent. The banners for the chelsea
pallete come from the collections of the Museum of London, as well as the rosette used for the classic
palette.
Want to help? Create a pull request or share the word: @d_alburez @ValentinaIemmi!