MyNixOS website logo
Description

Color Palettes Inspired by Video Games.

Palettes based on video games.

gameR

UsageReleaseDevelopment
License: GPL-3CRAN_Status_BadgeR-CMD-check
RgameR status badgecodecov
CRAN RStudio mirror downloadsProject Status: Active – The project has reached a stable, usable state and is being actively developed.
Tidyverse style guide

R color palettes inspired by video games.

[!NOTE] These color palettes may not be color blind friendly. If accessibility is a priority, I recommend either using the virdis package or checking your plots before sharing using tools which simulate color blindness (such as coblis).

Table of Contents

Installation

gameR is on CRAN! Install the stable version of gameR with:

install.packages("gameR")

You can install the development version of gameR, which may contain additional palettes, from r-universe with

# Enable universe(s) by nathansam
options(repos = c(
  nathansam = "https://nathansam.r-universe.dev",
  CRAN = "https://cloud.r-project.org"
))

install.packages("gameR")

Getting started

library(gameR)
library(ggplot2)

gameR provides either discrete color palettes or continuous palettes generated by interpolating a discrete palette. Discrete palettes and continuous palettes are provided via the gameR_cols() and gameR_cont() functions respectively. For a full list of the palettes provided by gameR, call one of these functions without any arguments.

gameR_cols()
#>  [1] "banjo"     "blocks"    "border"    "cowboy"    "cups"      "cyberpunk"
#>  [7] "fallout"   "gris"      "kirby"     "ocarina"   "okami"     "p3r"      
#> [13] "p4g"       "pman"      "rayman"    "sonic"     "spirit"    "splat"    
#> [19] "superbros" "wow"

Palettes

The following palettes are ordered alphabetically by the name of the game which inspired the palette.

Banjo-Kazooie

gameR_cols("banjo")

Borderlands

gameR_cols("border")

Cuphead

gameR_cols("cups")

Cyberpunk

gameR_cols("cyberpunk")

Fallout

gameR_cols("fallout")

Gris

gameR_cols("gris")

Kirby

gameR_cols("kirby")

Legend of Zelda: Ocarina of Time

gameR_cols("ocarina")

Okami

gameR_cols("okami")

Pac-Man

gameR_cols("pman")

Persona 3 Reload

gameR_cols("p3r")

Persona 4 Golden

gameR_cols("p4g")

Rayman

gameR_cols("rayman")

Red Dead Redemption II

gameR_cols("cowboy")

Sonic the Hedgehog

gameR_cols("sonic")

Spiritfarer

gameR_cols("spirit")

Splatoon

gameR_cols("splat")

Super Mario Bros

gameR_cols("superbros")

Tetris

gameR_cols("blocks")

World of Warcraft

gameR_cols("wow")

Contributing new palettes

Contributions via pull requests are welcome! I would love to have as many video games represented as possible. With that said, there are two requirements I ask of any contributed palettes:

  1. The palette must be at least somewhat distinctive. There are many popular and beloved games, but if the palette suggestion does not evoke the video game that inspired it, it probably should not be contributed.
  2. Please avoid trademarked names for palette names. I am not entirely sure how far the CRAN policy extends when it comes to trademarked names, but I would rather not risk running afoul of CRAN policy.

Adding a New Palette to the gameR Palette List

Adding a new palette is as simple adding a new element to the gameR_colors list in R/palettes.R, and calling devtools::document() from R to update the package documentation.

Updating the README

The README is generated by README.Rmd. Please update this file with the palettes you are contributing (the palettes are in alphabetical order), and knit the file before committing and pushing your contributions.

Credit

If you are contributing palette(s), I would love for your contribution to be recognized. Please feel free to add yourself as a contributor (role = “ctb”) in the DESCRIPTION file.

Metadata

Version

0.0.6

License

Unknown

Platforms (75)

    Darwin
    FreeBSD
    Genode
    GHCJS
    Linux
    MMIXware
    NetBSD
    none
    OpenBSD
    Redox
    Solaris
    WASI
    Windows
Show all
  • aarch64-darwin
  • aarch64-genode
  • aarch64-linux
  • aarch64-netbsd
  • aarch64-none
  • aarch64_be-none
  • arm-none
  • armv5tel-linux
  • armv6l-linux
  • armv6l-netbsd
  • armv6l-none
  • armv7a-darwin
  • armv7a-linux
  • armv7a-netbsd
  • armv7l-linux
  • armv7l-netbsd
  • avr-none
  • i686-cygwin
  • i686-darwin
  • i686-freebsd
  • i686-genode
  • i686-linux
  • i686-netbsd
  • i686-none
  • i686-openbsd
  • i686-windows
  • javascript-ghcjs
  • loongarch64-linux
  • m68k-linux
  • m68k-netbsd
  • m68k-none
  • microblaze-linux
  • microblaze-none
  • microblazeel-linux
  • microblazeel-none
  • mips-linux
  • mips-none
  • mips64-linux
  • mips64-none
  • mips64el-linux
  • mipsel-linux
  • mipsel-netbsd
  • mmix-mmixware
  • msp430-none
  • or1k-none
  • powerpc-netbsd
  • powerpc-none
  • powerpc64-linux
  • powerpc64le-linux
  • powerpcle-none
  • riscv32-linux
  • riscv32-netbsd
  • riscv32-none
  • riscv64-linux
  • riscv64-netbsd
  • riscv64-none
  • rx-none
  • s390-linux
  • s390-none
  • s390x-linux
  • s390x-none
  • vc4-none
  • wasm32-wasi
  • wasm64-wasi
  • x86_64-cygwin
  • x86_64-darwin
  • x86_64-freebsd
  • x86_64-genode
  • x86_64-linux
  • x86_64-netbsd
  • x86_64-none
  • x86_64-openbsd
  • x86_64-redox
  • x86_64-solaris
  • x86_64-windows