Scilab Website | Contribute with GitLab | Mailing list archives | ATOMS toolboxes
Scilab Online Help
2026.0.0 - English


Predefined colormaps

Overview of predefined colormaps.

Syntax

cmap = $colormapfunction$() // Replace $colormapfunction$ by the name of a function described below
cmap = $colormapfunction$(n)

Arguments

n

integer value, the colormap size.

It not provided for continuous/sequential/diverging colormaps, the default size is the size of the current (See gcf()) figure colormap, or the size of the default (See gdf()) figure colormap (if no figure is opened).

It not provided for discrete/qualitative colormaps, the default size is the size of the base pattern (fixed colors) depending on the colormap type (see below in colormaps description).

cmap

matrix with 3 columns [R,G,B].

Sample

Description

All these functions provide predefined continuous/sequential/diverging colormaps for Scilab graphics:

autumn

Computes a colormap with n colors varying from red through orange to yellow.

bone

Computes a gray colormap with n colors with a light blue tone.

cool

Computes a colormap with n colors varying from cyan to magenta.

copper

Computes a colormap with n colors varying from black to a light copper tone.

gray

Computes a colormap with n gray colors varying linearly from black to white.

hot

Computes a colormap with n hot colors varying from red to yellow.

hsv

Computes a colormap with ncolors. This colormap varies the hue component of the hsv color model. The colors begin with red, pass through yellow, green, cyan, blue, magenta, and return to red. The map is particularly useful for displaying periodic functions.

jet

Computes a colormap with n colors varying from blue, lightblue, green, yellow, orange then red.

ocean

Computes a colormap with with n blue colors varying linearly from black to white.

parula

Computes a colormap with n colors varying from blue to yellow.

pink

Computes a colormap that provides sepia tone colorization on black and white images.

rainbow

Computes a colormap with n colors varying from red through orange, yellow, green,blue to violet.

spring

Computes a colormap with n colors varying from magenta to yellow.

summer

Computes a colormap with n colors varying from green to yellow.

turbo

Computes a colormap with n colors varying from blue, lightblue, green, yellow, orange then red (quite similar to jet but perceptually uniform).

white

Computes a completely white colormap with n colors.

winter

Computes a colormap with n colors varying from blue to green.

blues

Computes a sequential single-hue blue colormap with n colors.

BrBG

Computes a diverging multi-hue colormap with n colors varying from brown to green hue through blue.

BuGn

Computes a sequential multi-hue colormap with n colors varying from blue to green hue.

BuPu

Computes a sequential multi-hue colormap with n colors varying from blue to purple hue.

coolwarm

Computes a sequential multi-hue colormap with n colors varying from blue to red hue.

GnBu

Computes a sequential multi-hue colormap with n colors varying from green to blue hue.

greens

Computes a sequential single-hue green colormap with n colors.

greys

Computes a sequential single-hue grey colormap with n colors.

oranges

Computes a sequential single-hue orange colormap with n colors.

OrRd

Computes a sequential multi-hue colormap with n colors varying from orange to red hue.

PiYG

Computes a diverging multi-hue colormap with n colors varying from pink to green hue through yellow.

PRGn

Computes a diverging multi-hue colormap with n colors varying from purple to green hue through red.

PuBu

Computes a sequential multi-hue colormap with n colors varying from purple to blue hue.

PuBuGn

Computes a sequential multi-hue colormap with n colors varying from purple to blue hue through green.

PuOr

Computes a diverging multi-hue colormap with n colors varying from purple to orange hue.

PuRd

Computes a sequential multi-hue colormap with n colors varying from purple to red hue.

purples

Computes a sequential single-hue purple colormap with n colors.

RdPu

Computes a sequential multi-hue colormap with n colors varying from red to purple hue.

RdYlBu

Computes a diverging multi-hue colormap with n colors varying from red to blue hue through yellow.

RdYlGn

Computes a diverging multi-hue colormap with n colors varying from red to green hue through yellow.

reds

Computes a sequential single-hue red colormap with n colors.

spectral

Computes a diverging multi-hue spectral colormap with n colors.

RdBu

Computes a diverging multi-hue colormap with n colors varying from red to blue.

RdGy

Computes a diverging multi-hue colormap with n colors varying from red to grey hue.

YlGn

Computes a sequential multi-hue colormap with n colors varying from yellow to green hue.

YlGnBu

Computes a sequential multi-hue colormap with n colors varying from yellow to green hue through blue.

YlOrBr

Computes a sequential multi-hue colormap with n colors varying from yellow to orange hue through brown.

YlOrRd

Computes a sequential multi-hue colormap with n colors varying from yellow to orange hue through red.

All these functions provide predefined discrete/qualitative colormaps for Scilab graphics:

flag

Computes a qualitative colormap with n colors cycling through 4 fixed colors (red, white, blue, and black).

prism

Computes a qualitative colormap with n colors cycling through 6 fixed colors (red, orange, yellow, green, blue and violet).

Accent

Computes a qualitative colormap with n colors cycling through 8 fixed colors (See https://colorbrewer2.org/).

Dark2

Computes a qualitative colormap with n colors cycling through 8 fixed colors (See https://colorbrewer2.org/).

Paired

Computes a qualitative colormap with n colors cycling through 12 fixed colors (See https://colorbrewer2.org/).

Pastel1

Computes a qualitative colormap with n colors cycling through 9 fixed colors (See https://colorbrewer2.org/).

Pastel2

Computes a qualitative colormap with n colors cycling through 12 fixed colors (See https://colorbrewer2.org/).

Set1

Computes a qualitative colormap with n colors cycling through 9 fixed colors (See https://colorbrewer2.org/).

Set2

Computes a qualitative colormap with n colors cycling through 12 base colors (See https://colorbrewer2.org/).

Set3

Computes a qualitative colormap with n colors cycling through 12 base colors (See https://colorbrewer2.org/).

See also

  • Colormaps — Using colormaps in graphics.
  • colormap — set and/or get a figure/axes colormap.

History

VersionDescription
2024.1.0 Default colormap size is now based on the size of the current or default figure colormap size.
2024.1.0 Colormap functions renamed to autumn, bone, cool, copper, gray, hot, hsv, jet, ocean, parula, pink, rainbow, spring, summer, white, winter.
2024.1.0 New colormap functions blues, BrBG, BuGn, BuPu, coolwarm, GnBu, greens, greys, oranges, OrRd, PiYG, PRGn, PuBu, PuBuGn, PuOr, PuRd, purples, RdBu, RdGy, RdPu, RdYlBu, RdYlGn, reds, spectral, YlGn, YlGnBu, YlOrBr, YlOrRd introduced.
2025.1.0 New colormaps functions turbo, flag, prism, Accent, Dark2, Paired, Pastel1, Pastel2, Set1, Set2, Set3 introduced.
2026.0.0 Functions autumncolormap, bonecolormap, coolcolormap, coppercolormap, graycolormap, hotcolormap, hsvcolormap, jetcolormap, oceancolormap, parulacolormap, pinkcolormap, rainbowcolormap, springcolormap, summercolormap, whitecolormap, wintercolormap removed.
Report an issue
<< Using colormaps Colormaps addcolor >>

Copyright (c) 2022-2025 (Dassault Systèmes S.E.)
Copyright (c) 2017-2022 (ESI Group)
Copyright (c) 2011-2017 (Scilab Enterprises)
Copyright (c) 1989-2012 (INRIA)
Copyright (c) 1989-2007 (ENPC)
with contributors
Last updated:
Thu Oct 16 09:02:34 CEST 2025