Skip to main content
100%

Fork of Bar Chart

✓ Published0🌍 Public
JJustin Roberts
Last edited Mar 8, 2023
Created on Mar 8, 2023
Forked from Bar Chart

This example displays a horizontal bar chart comparing two categories, female and male, by count, using data loaded from a CSV file. The visualization uses D3 v7 with SVG rendering, where `d3.scaleLinear` maps count values to bar widths and `d3.scaleBand` positions the categorical y-axis. Axes are generated with `d3.axisLeft` and `d3.axisBottom`, with the x-axis formatted using `d3.format` to abbreviate large numbers. The chart is styled with steelblue rectangles and demonstrates a simple, clean layout with custom margins.

AI-generated description
MIT Licensed

Similar vizzes