Line chart with d3.brush
✓ Published0🌍 Public
TThanaporn-sk
Last edited Mar 9, 2017
Created on Mar 9, 2017
This example shows monthly S&P 500 index prices from 2000 to 2010 as a line chart with a brushable timeline below it. The main chart displays the full time series in steelblue, while the lower context chart uses d3.brushX to select a range for zooming. The code enforces a minimum one-year selection window, and d3.zoom synchronizes panning and zooming with the brush. Data is loaded from a CSV file using the queue library, and all rendering uses SVG with d3.v4.
AI-generated descriptionBuilt with blockbuilder.org
forked from <a href='http://bl.ocks.org/twlynch/'>twlynch</a>'s block: <a href='http://bl.ocks.org/twlynch/24fc6c48058e575576915479c8ae8ab5'>Line chart with d3.brush</a>
none Licensed