Skip to main content
100%

Color in Data Visualization

✓ Published0🌍 Public
CCurran Kelleher
Last edited Oct 9, 2025
Created on Jul 24, 2025
Forked from Circles with D3

This gallery example visualizes five fundamental color-scale patterns—sequential, diverging, categorical, highlight, and alert—through a grid of annotated mini bar charts. Each pattern shows how color encodes quantitative or categorical data, using palettes like blues for sequential, diverging browns and greens, and gray tints with accent colors for highlighting. The D3 v7 code uses `scaleLinear` and `scaleBand` to compute bar heights, while custom wrapping logic measures text via `getComputedTextLength`. The layout is fixed with responsive container sizing, and the visualization is based on concepts from "The Big Book of Dashboards."

AI-generated description

A re-creation / reimagining of a classic graphic on color from "The Big Book of Dashboards" by Steve Wexler, Jeffrey Shaffer, and Andy Cotgreave.

Color Scale Patterns in Data Visualization

This infographic demonstrates the five basic color-scale patterns used in data visualization:

Color Scale Types

  1. Sequential - Color is ordered from low to high, typically encoding quantitative or ordinal data
  2. Diverging - Two sequential colors with a neutral midpoint, used for scales showing two different outcomes
  3. Categorical - Contrasting colors for individual comparisons, each representing a specific category
  4. Highlight - Color used to call attention to specific data points, used with gray tints
  5. Alert - Color used to get user attention, using attention-grabbing colors like red or orange

Each pattern is illustrated with a mini bar chart, color swatches, and descriptive text to demonstrate the appropriate use case and visual encoding.

MIT Licensed

Similar vizzes