Patchwork Color Palette
Description
Examples
The Patchwork plot palette is a collection of bright colors, originally designed to yield attractive maps. See for example the WorldMap object. It is designed for coloring collections of filled areas. There are ten colors in the palette.
ColorTools:-DisplayPalette("Patchwork",noextend);
1. Blue
2. RedOrange
3. BluePurple
4. Red
5. DarkBlue
6. Yellow
7. DarkGreen
8. DarkRed
9. Green
10. PaleBlue
You can reference colors in the palette by name or number in most commands that understand color names.
plot⁡x,x3,x=−1..1,color=Patchwork 2,Patchwork Blue
C≔ColorTools:-Color⁡Patchwork 10
C≔〈RGB : 0.42 0.725 0.941〉
You can make Patchwork the default palette in plots using setcolors
plots:-setcolors⁡Patchwork:
You can programatically access the colors using ColorTools commands
P≔ColorTools:-GetPalette⁡Patchwork
P≔Palette Patchwork:⁢Blue⁢RedOrange⁢BluePurple⁢Red⁢DarkBlue⁢Yellow⁢DarkGreen⁢DarkRed⁢Green⁢PaleBlue
P1
〈RGB : Blue〉
n≔numcolors⁡P
n≔10
plot⁡seq⁡sin⁡x+i⁢πn,i=1..n,x=0..2⁢π,axes=boxed,color=:-GetColors⁡P1..n,legend=:-GetColorNames⁡P1..n,numpoints=25,style=point,symbol=solidcircle
ColorTools algorithms will automatically generate new colors beyond the main 10 colors:
P20
〈RGB : 0.987 0.565 0.344〉
The Patchwork palette is designed for filled areas, but the Lookup command can provide slightly altered shades of its colors for use in coloring points or lines.
Lookup⁡P,1,shade=line
〈RGB : 0.148 0.312 0.596〉
Lookup⁡P,1,shade=point
〈RGB : 0.0754 0.25 0.54〉
See Also
ColorTools
ColorTools[DisplayPalette]
ColorTools[Palette]
ColorTools[Palettes][Lookup]
plots[setcolors]
Download Help Document