Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

making a vertical bar chart

Public visualization

Viewing a saved revision (read-only)

504276ef8b524d329ee0b0535d54b7de

making a vertical bar chart

0 stars1🌍 Public
VVvgupta
Last edited Mar 11, 2020
Created on Mar 11, 2020

This example shows a vertical bar chart of lettered categories (a–m) and their corresponding numerical values, with red bars and labeled axes. The chart uses D3 v5 to load comma-separated data via `d3.csv`, then applies `d3.scaleBand` for the x-axis and `d3.scaleLinear` for the y-axis. Axes are rendered with `d3.axisLeft` and `d3.axisBottom`, and the bars are appended as SVG `<rect>` elements. The layout uses a fixed margin and inner dimensions, with the y-axis range inverted to align zero at the bottom.

AI-generated description