FAQ
- find your data type
- choose what feature of data do you wnat to highlight (representation task or goal of the visualisation)
- choose gradient type ( discrete/continous )
- choose your specific gradient
- Optimizing colormaps with consideration for
- color vision deficiency
- spatial patterns, especially the boundary characteristics - Data-Driven Colormap optimization
Note that :
Examples:
- matplotlib
- seaborn
- Subtleties of Color by Robert Simmon
- Color Use Guidelines for Mapping and Visualization by Cindy Brewer
- How to choose a color palette for choropleth maps by Lisa Charlotte Rost
- find colour map / gradient type
- choose (to do !)
- Polynomial Regression
- polysolve by Paul Lutus- online tool which gives a c function as an output ( click on the output form button to cycle through the available output forms)
- simplest_regression.py - python program (Polynomial solver) by Paul Lutus
- numpy polyfit
Tools:
- gedit : replace "," with \t
- LibreOffice Calc ( opens cvs files, choose columns, remove columns)), see note about importing scv files for polish settings by Mirosław Zalewski
- Useful Color Equations by Bruce Justin Lindbloom
- HSLuv-C: Human-friendly HSL = C implementation of HSLuv (revision 4)
- HSLUV : the necessary mathematical equations are solved in Maxima.
- coloralgorithm : js code from lyft
- Color math and programming code examples by easyrgb
- elative-colorimetric-and-perceptual-rendering-intent by Arnaud Frich
- stackoverflow question: algorithm-to-convert-rgb-to-hsv-and-hsv-to-rgb-in-range-0-255-for-both
- HSP Color Model — Alternative to HSV (HSB) and HSL by Darel Rex Finley.
- HSV Color Space by Ronja Böhringer
- Paul Bourke: colourspace
- OpenCV - color conversion
- online
- TLBX: COLOR CONVERTER
- colorizer
- rapidtables: rgb
- rapidtables: hsv-to-rgb
- chroma.js is a small-ish zero-dependency JavaScript library (13.5kB) for all kinds of color conversions and color scales by Gregor Aisch, Example pf use
- Color::TupleEncode | Mapping tuples to colors by Martin Krzywinski
- rgb.to
- colr.org
- thecolorapi
- encycolorpedia
colormap generation techniques:
- procedural methods focused on addressing data perception problems
- user-study based methods
- rule-based methods
- data-driven methods;
- Interactive Creation of Perceptually Uniform Color Maps by M. Lambers (EUROVIS 2020)
- CCC-Tool - general tool for the creation, export, analyzing and testing of colormaps
- Interactive web tool to generate custom colormaps for Matplotlib / Matlab by Jon Herman
- ColorCAT
- gencolormap
- palettte app by Gabriel Adorf
- Kenneth Moreland
- "interpolate colors in a perceptually designed space (such as CIELAB or one of its derivatives like CIELch) rather than in basic RGB space."
- Making a gradient in perceptual space is pretty straightforward. Simply convert the RGB values to a perceptual space (such as CIELAB or CIELch) and interpolate in that space. For each value, convert back to RGB. I would find a convenient library that does these conversions for you. For example, for Python I use the colormath package: https://python-colormath.readthedocs.io/en/latest/.
- The Colour Map Design Process by Peter Kovesi
- Good Colour Maps: How to Design Them by Peter Kovesi ( arxiv)
- Good Colour Maps: How to Design Them by Peter Kovesi (page)
- How to use viscm to design colormaps for paraview-4-4 by Cory Quammen
- Lyft Design: Javacript function to produce color sets: color lightness-to-darkness consistent across color hues, so that every color 0–50 is accessible (4.5:1) on black, and every color 60–100 is accessible (4.5:1) on white.
- mathematica.se question: how-to-calculate-mix-of-4-colors-defined-in-cielab-lab-model
- Color Sequence Editor Using CIEluv Uniform Color Space by Evan Oliveri and Colin Ware
- chromatic-sketch: Create good-looking and perceptually uniform gradients and color scales (using Chroma.js and the Lab color space)
- cosine procedural palete by Inigo Quilez: "Mine cosine based palette generator is mostly designed for small demos where the size of the code matters, but otherwise it's not very powerful nor expressive."
- "Translating the creation of quantitative schemes into a multiconstraint optimization problem"An adaptive approach to create on‐demand color schemes for mapping quantitative geographic data Mingguang Wu Taisheng Chen Hong Wang Guonian Lv A‐Xing Zhu
- data-color-picker
- Colour displays for categorical images by Glasbey et al. (2007)
- stackoverflow question: how-to-generate-a-number-of-most-distinctive-colors-in-r
- Chroma.js Color Palette Helper - tool for mastering multi-hued, multi-stops color scales by Gregor Aisch
- avoid-equidistant-hsv-colors by Gregor Aisch
- stackoverflow question : how-to-automatically-generate-n-distinct-colors
/*
https://stackoverflow.com/questions/470690/how-to-automatically-generate-n-distinct-colors
You can use the HSL color model to create your distinct colors.
If all you want is differing hues (likely), and slight variations on lightness or saturation, you can distribute the hues like so:
assumes hue [0, 360), saturation [0, 100), lightness [0, 100)
*/
for(i = 0; i < 360; i += 360 / num_colors) {
HSLColor c;
c.hue = i;
c.saturation = 90 + randf() * 10;
c.lightness = 50 + randf() * 10;
addColor(c);
}
- What-are-some-good-experiments-to-see-that-the-CIE-LAB-color-space-is-a-perceptually-uniform-color-space
- MacAdam_ellipse
-
tests
- CCC-Tool - general tool for the creation, export, analyzing and testing of colormaps
- colormeasures - only gradients in a json form
- pal.test from the ‘pals’ package by Kevin Wright
- colormap inxpections from ethplot
- How to evaluate and compare colormaps by Matteo Niccoli, MyCarta
- colourmap evaluation = assessing colormap quality by Stéfan van der Walt and Nathaniel Smith using viscm
- How Bad Is Your Colormap? by Jake VanderPlas
- draw a gradient on the colorwheel
-
test image or palette visualisation
- spatial frequency
- CET Perceptually Uniform Colour Maps: The Test Image by Peter Kovesi:A sine wave superimposed on a ramp
- Colormap Test Image by Steve Eddins, July 24, 2017
- Campbell-Robson Contrast Sensitivity Chart
- Campbell-Robson CSF images by Izumi OHZAWA (ohzawa) and his page
- a spatial contrast sensitivity function
- pals test image
- colormanagement : test images
- Altona Test Suite from ECI = European Color Initiative
- heatmap based on the Maunga Whau volcano data
- path ( trajectory)
- in the color space
- on the colorwheel
- pyramid
- RGB_24bits_palette_color_test_chart
- Color proportions of an image by L. Jégou
- pinestrripe image
- Which Blair Project - a quick visual method for evaluating perceptual color maps. Users choose gradient with monotically increasing luminance
- ImaTest - Imatest provides customers with software, charts and equipment to meet and exceed image quality testing standards.
- The Koren lens test chart
- spatial frequency
-
spectrum
- RGB spectrum or gnuplot RGB profiles of current color palette ( do not confuse with ICC color profiles) or channels
- HCL spectrum
-
3D plot
"separate the calculation phase from the colouring phase" Claude Heiland-Allen
- compute data
- compute choose gradient
- apply gradient to the data = output image
- data in pgm file
- gradient as a clut in ppm file
- use Image magic convert to apply gradient using options:
- clut : replace the channel values in the first image using each corresponding channel in the second image as a color lookup table
- interpolate: Set the pixel color interpolation method. Good settings for this are the 'bilinear' and 'bicubic' interpolation settings, which give smooth color gradients, and the 'integer' setting for a direct , unsmoothed lookup of color values.
convert input.pgm -level 0,65532 clut.ppm -interpolate integer -clut -depth 8 output.png
- axial : x or y variable ( horizontal or vertical axis), goes down/up/left/right/diagonally - see CSS linear gradient
- radial: magnitude of the complex variable - see CSS radiel gradient: starts at a single point and emanates outward
- conic : angle of the complex variable - see CSS conic gradient, see for example color wheel
- any other real variable in [0,1] range ( or normalized to that range or used as a repeating gradients)
- The Secrets of Colour Interpolation in rgb by Alan Zucconi
- stackoverflow question : interpolate-from-one-color-to-another
- Interpolation methods Written by Paul Bourke December 1999
// Precise method, which guarantees v = v1 when t = 1.
double lerp(double v0, double v1, doublet t) {
return (1 - t) * v0 + t * v1;
Papers: