Skip to main content
100%

Stacked-to-Grouped Police Killings

✓ Published0🌍 Public
NNastasi7
Last edited Sep 18, 2015
Created on Sep 18, 2015

This example visualizes police killings in 2015 (through June) as a bar chart broken down by race and month. Users can toggle between stacked and grouped layouts, with animated transitions that preserve object constancy across views. The code uses D3.js (v3) for data binding, scales, axes, and transitions, processing data from a CSV file. The visualization includes a legend and radio buttons to switch between the two layout modes.

AI-generated description

Switch between stacked and grouped layouts using sequenced transitions! Animations preserve object constancy and allow the user to follow the data across views. Animation design by Heer and Robertson. Colors and data generation inspired by Byron and Wattenberg.

Police killings data for 2015 (up to June) downloaded from FiveThirtyEight

forked from <a href='http://bl.ocks.org/mbostock/'>mbostock</a>'s block: <a href='http://bl.ocks.org/mbostock/3943967'>Stacked-to-Grouped Bars</a>

forked from <a href='http://bl.ocks.org/enjalot/'>enjalot</a>'s block: <a href='http://bl.ocks.org/enjalot/2b1446f496c3968f6ecd'>Stacked-to-Grouped Police Killings</a>

Similar vizzes