Skip to content

Latest commit

 

History

History
239 lines (135 loc) · 3.68 KB

README.md

File metadata and controls

239 lines (135 loc) · 3.68 KB

Build Status

Wes Anderson Palettes

I saved you from boring plots. What did you ever do? - Max Fischer (probably)

Tired of generic mass produced palettes for your plots? Short of adding an owl and dressing up your plot in a bowler hat, here's the most indie thing you can do to one. First round of palettes derived from the amazing Tumblr blog Wes Anderson Palettes.

install.packages("wesanderson")

Or the development version

devtools::install_github("karthik/wesanderson")

Current list of available palettes

library(wesanderson)
namelist
movies wesnums
GrandBudapest 4
Moonrise1 4
Royal1 4
Moonrise2 4
Cavalcanti 5
Royal2 5
GrandBudapest2 4
Moonrise3 5
Chevalier 4
Zissou 5
FantasticFox 5
Darjeeling 5
Rushmore 5
BottleRocket 7
Darjeeling2 5

See the palettes

Grand Budapest

display.wes.palette(4, "GrandBudapest")

display.wes.palette(4, "GrandBudapest2")

ggplot(iris, aes(Sepal.Length, Sepal.Width, color = Species)) + 
geom_point(size = 3) + 
scale_color_manual(values = wes.palette(3, "GrandBudapest")) + 
theme_gray()

Moonrise Kingdom

display.wes.palette(4, "Moonrise1")

display.wes.palette(4, "Moonrise2")

display.wes.palette(5, "Moonrise3")

Royal Tannenbaums

display.wes.palette(4, "Royal1")

display.wes.palette(5, "Royal2")

qplot(factor(cyl), data=mtcars, geom="bar", fill=factor(vs)) + 
scale_fill_manual(values = wes.palette(2, "Royal1"))

Castello Cavalcanti

display.wes.palette(5, "Cavalcanti")

Hotel Chevalier

display.wes.palette(4, "Chevalier")

The Life Aquatic

display.wes.palette(5, "Zissou")

pal <- wes.palette(name = "Zissou", type = "continuous")
image(volcano, col = pal(21))

library(wesanderson)
pal <- wes.palette(name = "Zissou", type = "continuous")
# heatmap is a local dataset
ggplot(heatmap, aes(x = X2, y = X1, fill = value)) +
 geom_tile() + 
 scale_fill_gradientn(colours = pal(100)) + 
scale_x_discrete(expand = c(0, 0)) +
scale_y_discrete(expand = c(0, 0)) + coord_equal() 

Darjeeling Limited

display.wes.palette(5, "Darjeeling")

display.wes.palette(5, "Darjeeling2")

Fantastic Mr. Fox

display.wes.palette(4, "FantasticFox")

Rushmore

display.wes.palette(4, "Rushmore")

Bottle Rocket

Coming soon


Gallery of examples