Skip to main content
Public

Share visualization

Loading preview…

Activity6_Task1_Tutorial_Alt

vizhub.com

Shared links may look like this on X, LinkedIn, Slack, and Discord.

Before sharing, review the publishing checklist.

Choose how to deliver this visualization

LinkedIn caption

LinkedIn may not keep text supplied by the share sheet. Copy the caption and paste it into the post if needed. You can tag the VizHub company page when posting.

More options

Embed on a websiteCopy iframe embed code
Download & exportPNG, HTML, source ZIP

Activity6_Task1_Tutorial_Alt

0
Mmaheshsachin1234@gmail.com
Last edited Mar 28, 2025
Created on Mar 28, 2025

This horizontal bar chart displays the top 30 countries by 2020 population, using green bars to compare values across a blue-ticked axis. The visualization loads CSV data from a GitHub gist, parses the population column, and renders an SVG using D3 v7's `scaleLinear`, `scaleBand`, and `d3.axisBottom`/`axisLeft`. Custom ES6 modules (`Marks.js`, `AxisBottom.js`, `AxisLeft.js`) encapsulate the bar drawing and axis formatting, with tick labels formatted in compact notation (e.g., "1.2B").

AI-generated description

An example showing the capabilities of VizHub:

  • Loads D3 via UNPKG (pinned at v6, since this runtime environment only supports UMD, and in v7 D3 dropped UMD support)
  • Demonstrates use of import from "d3".
  • Demonstrates use of import from local ES6 modules.

Comments

Sign in to join the discussion.

MIT Licensed