Skip to main content
100%

Customizing Axes

✓ Published0🌍 Public
KKanagaraj-NN
Last edited Nov 25, 2018
Created on Nov 25, 2018
Forked from Customizing Axes

This example shows a horizontal bar chart of suspicious code lines ranked by ID, with populating data from a CSV file. It demonstrates how to customize D3 axes: the y-axis removes its domain and tick lines, while the x-axis uses a custom tick formatter (format('.3s')) to abbreviate numbers, replacing 'G' with 'B'. Data is loaded via d3.csv and rendered as SVG rectangles using scaleLinear and scaleBand. Axis labels and a title are added with custom styling through styles.css.

AI-generated description

This bar chart shows population of the top 10 most populous countries. The data comes from the year 2018 estimate in United Nations: World Population Prospects 2017.

MIT Licensed

Similar vizzes