Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

NYC Crash Bar Chart with React & D3

Public visualization

Viewing a saved revision (read-only)

7ac8fc41c49244fd9a27c5203e28631b

NYC Crash Bar Chart with React & D3

0 stars3🌍 Public
JJose Morales
Last edited Sep 25, 2025
Created on Sep 25, 2025

This bar chart visualizes the number of vehicle collisions in New York City across the 24 hours of a day, breaking down each hour's total into stacked segments for injuries, deaths, and other crashes. The chart uses React to manage the SVG and window resizing, while D3's `scaleLinear`, `axisBottom`, and `stack` APIs handle the data scaling, axes, and stacked bar construction. Data is loaded from a local CSV file.

AI-generated description