display.all.met: View all Available Palettes

View source: R/PaletteCode.R

display.all.metR Documentation

View all Available Palettes

Description

Function for viewing all palettes available in MetBrewer.

Usage

display.all.met(
  n,
  sequential = FALSE,
  colorblind_only = FALSE,
  direction = 1,
  override_order = FALSE
)

Arguments

n

Number of requested colors. If n is left blank, default palette is returned.

sequential

Should palettes displayed all at once, or one at a time. Default is all at once (FALSE).

colorblind_only

Should only colorblind friendly palettes be returned? Default is set to FALSE.

direction

Sets order of colors. Default palette is 1. If direction is -1, palette color order is reversed

override_order

Colors are picked from palette to maximize readability and aesthetics. This means that colors are not always selected in sequential order from the full palette. If override_order is set to TRUE, colors are selected in sequential order from the full palette instead. Default is FALSE.

Examples

# All Palettes
display.all.met(sequential = FALSE, colorblind_only = FALSE)

# All Colorblind Palettes
display.all.met(sequential = FALSE, colorblind_only = TRUE)

# 5 Colors of all Palettes
display.all.met(5, sequential = FALSE, colorblind_only = FALSE)

BlakeRMills/MetBrewer documentation built on Jan. 6, 2025, 9:29 p.m.