Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Fork of Bar chart with a Sequential color scale

Public visualization

Viewing a saved revision (read-only)

bc358e63bbdc4b3c9f4a0dee33f237d5

Fork of Bar chart with a Sequential color scale

0 stars0🌍 Public
SShishiraRudrabhatla
Last edited Jul 6, 2022
Created on Jul 6, 2022

This bar chart displays the average horsepower for seven car brands, sorted from lowest to highest, with each bar colored according to a sequential red color scale that encodes the horsepower value. The visualization loads data from a CSV file using d3.csv, binds it to SVG rectangles, and uses d3.scaleBand, d3.scaleLinear, and d3.scaleQuantize for positioning and color mapping. Interactive tooltips appear on mouseover, while d3.legendColor adds a legend, and axes are rendered with d3.axisBottom and d3.axisLeft.

AI-generated description