Skip to main content
100%

Brushable Scatterplot/Choropleth

✓ Published0🌍 Public
TThanaporn-sk
Last edited Mar 9, 2017
Created on Mar 9, 2017

A brushable scatterplot shows adult obesity rates versus median household income for U.S. states, with each state represented as a colored dot. The plot uses d3.brush to let users select a region, which filters the adjacent choropleth map to highlight only the selected states. The map, rendered with d3.geoPath and d3.geoAlbersUsa, colors states by their obesity rate using a d3.scaleThreshold. Data comes from the State of Obesity project and the 2014 ACS, with interactions updating both charts via shared callbacks.

AI-generated description

Block-a-Day #2. A brush interaction on a scatterplot filters a choropleth showing the Y axis variable.

Data Sources: State of Obesity and 2014 ACS.

What I Learned: This is kinda a quickie as I ran into an issue with the planned block, but I had never used D3-brush before.

What I'd Do With More Time: I'd probably add a mouseover to the map so the association between the charts is two-way.

Block-a-Day

Just what it sounds like. For fifteen days, I will make a D3.js v4 block every single day. Rules:

  1. Ideas over implementation. Do something novel, don't sweat the details.
  2. No more than two hours can be spent on coding (give or take).
  3. Every. Single. Day.

Previously

forked from <a href='http://bl.ocks.org/cmgiven/'>cmgiven</a>'s block: <a href='http://bl.ocks.org/cmgiven/abca90f6ba5f0a14c54d1eb952f8949c'>Brushable Scatterplot/Choropleth</a>

forked from <a href='http://bl.ocks.org/wqm9425/'>wqm9425</a>'s block: <a href='http://bl.ocks.org/wqm9425/5fd92b24e5e1c23b5bdf9ea5e5e2aa28'>Brushable Scatterplot/Choropleth</a>

mit Licensed

Similar vizzes