Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Making a Bar Chart

Public visualization

Making a Bar Chart

0 stars0🌍 Public
SSorin Neculae
Last edited Jun 25, 2020
Created on Jun 25, 2020
Forked from Making a Bar Chart

This example shows a horizontal bar chart of male population estimates for ten countries, ordered by descending value. The visualization encodes population numbers as bar lengths and country names along the vertical axis using an SVG rendering. The code uses d3.csv to load the data, d3.scaleLinear and d3.scaleBand for positioning and sizing, and d3.axisLeft and d3.axisBottom to draw the axes. Steel-blue rectangles represent the bars, with a 110-pixel left margin accommodating country labels.

AI-generated description

Comments

Sign in to join the discussion.

MIT Licensed