Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

pal_material

Material Design Color Palettes


Description

The Material Design color palettes.

Usage

pal_material(palette = c("red", "pink", "purple", "deep-purple", "indigo",
  "blue", "light-blue", "cyan", "teal", "green", "light-green", "lime",
  "yellow", "amber", "orange", "deep-orange", "brown", "grey", "blue-grey"),
  n = 10, alpha = 1, reverse = FALSE)

Arguments

palette

Palette type. There are 19 available options:

  • "red"

  • "pink"

  • "purple"

  • "deep-purple"

  • "indigo"

  • "blue"

  • "light-blue"

  • "cyan"

  • "teal"

  • "green"

  • "light-green"

  • "lime"

  • "yellow"

  • "amber"

  • "orange",

  • "deep-orange"

  • "brown"

  • "grey"

  • "blue-grey"

See the material design color guidelines for details.

n

Number of individual colors to be generated.

alpha

Transparency level, a real number in (0, 1]. See alpha in rgb for details.

reverse

Logical. Should the order of the colors be reversed?

Author(s)

Nan Xiao <me@nanx.me> | <https://nanx.me>

Examples

library("scales")
show_col(pal_material("indigo")(10))
show_col(pal_material("indigo", n = 30, alpha = 0.6, reverse = TRUE)(30))

ggsci

Scientific Journal and Sci-Fi Themed Color Palettes for 'ggplot2'

v2.9
GPL-3 | file LICENSE
Authors
Nan Xiao [aut, cre] (<https://orcid.org/0000-0002-0250-5673>), Miaozhu Li [ctb]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.