Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Bar Chart - Top 10 Highest Populated Countries

Public visualization

Viewing a saved revision (read-only)

b8afdccfa4414e64a3c6439095a7d081

Bar Chart - Top 10 Highest Populated Countries

0 stars0🌍 Public
VVishnu Sudireddy
Last edited Jul 26, 2023
Created on Jul 26, 2023
Forked from Hello VizHub

This bar chart shows the top 10 most populated countries, ranked by their GDP in USD. The visualization uses d3.csv to load world data from a remote GitHub-hosted CSV file, then sorts the data in descending order and selects the first ten entries. Rectangular bars are rendered in SVG, with d3.scaleBand and d3.scaleLinear mapping countries and GDP values to x and y positions. The code adds rotated x-axis labels for readability and applies d3.axisBottom and d3.axisLeft for the chart's axes.

AI-generated description