Skip to main content
100%

Sorting the Grid

✓ Published0🌍 Public
FFrissAnalytics
Last edited Sep 25, 2018
Created on Sep 25, 2018

64 circles in a square grid encode three random attributes: size, color, and id. Users sort the grid by clicking “sort by” links for id, size, or color. The d3.layout.grid library positions nodes in a fixed grid; the d3.comparator library builds multi-key sort comparators that reorder the data. Clicking triggers an animated transition using `node.transition()` with a stagger delay, moving circles to their new sorted positions while adjusting radius and fill via d3 scales.

AI-generated description

Grid layout in combination with multi-dimensional sorting using d3.comparator.

forked from <a href='http://bl.ocks.org/mayblue9/'>mayblue9</a>'s block: <a href='http://bl.ocks.org/mayblue9/e0403ef97c56deab5079ef1f5bc366db'>Sorting the Grid</a>

mit Licensed

Similar vizzes