Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Air bnb

Public visualization

Viewing a saved revision (read-only)

7b910019071e40d8941bcb6496359559

Air bnb

0 stars0🌍 Public
VVenkat-Dhulipalla
Last edited Mar 12, 2023
Created on Mar 11, 2023
Forked from D3 Starter

This visualization displays the top 10 most expensive Airbnb listings in New York City as a horizontal bar chart, using React to manage the component state and D3 v5 for scales, axes, and SVG rendering. The code loads CSV data via `d3.csv`, sorts by price, and slices the top 10 entries, then maps them to `scaleBand` and `scaleLinear` ranges. Bars are drawn as SVG `<rect>` elements with a red fill, while custom tick marks and labels are generated from the scales. The chart uses a light gray background and a simple title.

AI-generated description

A demonstration of how to start using D3 version 6.