Not too long ago, on a laptop not that far away...
sfPalettes is a library of colour palettes based on popular (and, perhaps, not so popular) science fiction movies. All colour palettes in this package were created using a number of publically available sources, including screenshots and posters.
sfPalettes was inspired by Kartik Ram's wesanderson package and Chris Hamm's spaceMovie Star Wars-themed package..
devtools::install_github("arcaravaggi/sfPalettes")
library(sfPalettes)
# See all palettes
names(SF_palettes)
## [1] "Hope" "Rogue" "Empire" "Jedi" "Menace" "Clones"
## [7] "Sith" "Force" "Jurassic" "Her" "Martian" "Sunshine"
## [13] "Future"
library("ggplot2")
ggplot(iris, aes(Sepal.Length, Sepal.Width, color = Species)) +
theme_bw() +
geom_point(size = 3) +
scale_color_manual(values = SF_palette("Hope")) +
labs(y = "Sepal width", x = "Sepal length") +
theme(legend.text = element_text(face = "italic"))
SF_palette("Hope")
SF_palette("Clones")
SF_palette("Future")
SF_palette("Sunshine")
pal <- SF_palette("Her", 21, type = "continuous")
image(volcano, col = pal)
SF_palette("Her")
pal <- SF_palette("Jurassic", 100, type = "continuous")
# heatmap is a local dataset
ggplot(heatmap, aes(x = X2, y = X1, fill = value)) +
geom_tile() +
scale_fill_gradientn(colours = pal) +
scale_x_discrete(expand = c(0, 0)) +
scale_y_discrete(expand = c(0, 0)) +
coord_equal()
SF_palette("Jurassic")
SF_palette("Rogue")
SF_palette("Jedi")
SF_palette("Sith")
qplot(factor(cyl), data=mtcars, geom="bar", fill=factor(vs)) +
scale_fill_manual(values = SF_palette("Sith"))
SF_palette("Empire")
SF_palette("Force")
SF_palette("Martian")
SF_palette("Menace")
Contributors are welcome to fork the package and suggest additions or improvements.
Please report it to the issue tracker. Please provide specific details, allowing the error to be reproduced and investigated. Always note the version of R you are using, along with any other relevant software (e.g. RStudio).
This package is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License, version 3, as published by the Free Software Foundation.
This program is distributed in the hope that it will be useful, but without any warranty; without even the implied warranty of merchantability or fitness for a particular purpose. See the GNU General Public License for more details.
A copy of the GNU General Public License, version 3, is available at https://www.r-project.org/Licenses/GPL-