Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

From bars to scatter plot with revert x and y

Public visualization

Viewing a saved revision (read-only)

4c6a439d11bb4e80bafcbfd75be2a373

From bars to scatter plot with revert x and y

0 stars1🌍 Public
FFrançois Plet
Last edited Jul 6, 2019
Created on Jul 6, 2019
Forked from custom axis

This example transforms a bar chart into a scatter plot by swapping the x and y axes, displaying country populations as evenly spaced circles with a fixed radius. The visualization uses D3 v5’s `scaleLinear` for the population axis and `scalePoint` for the categorical country axis, with `axisBottom` and `axisLeft` generating gridlines. Data comes from a local CSV loaded via `d3.csv`, and circles are appended to an SVG with click handlers that log each data point to the console.

AI-generated description