Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

ICE6-Nitheesh-Sama

Public visualization

ICE6-Nitheesh-Sama

0 stars1🌍 Public
NNitheeshSama
Last edited Mar 10, 2023
Created on Mar 10, 2023

This example displays a horizontal bar chart of employee salaries across different ages, using data from a CSV file loaded via `d3.csv`. The visualization renders as an SVG, with `d3.scaleBand` positioning the age categories on the y-axis and `d3.scaleLinear` mapping salary values to bar widths on the x-axis. React manages the state and lifecycle, fetching the data and slicing it to the first 15 records. Gridlines and tick labels are generated programmatically using D3’s scale methods, while the bars themselves are drawn as SVG `<rect>` elements.

AI-generated description

A bare minimum HTML page.

Comments

Sign in to join the discussion.

MIT Licensed