Skip to main content
🔗 Unlisted

Share visualization

Send this visualization to others.

Nivesh Syreddy Reusable D3 Scatter Plot

Unlisted visualization

Anyone with the link can view this unlisted visualization. Posting it publicly will make the link discoverable.

Viewing a saved revision (read-only)

c0d6de7a266e46b39e473b89cc243f43

Nivesh Syreddy Reusable D3 Scatter Plot

0 stars1🔗 Unlisted
Nniveshsyreddy@gmail.com
Last edited Apr 1, 2025
Created on Mar 31, 2025

This animated scatter plot visualizes medical insurance charges against patient age and BMI, with points colored by smoking status using a categorical color scale. Built with D3 v6, it uses `scaleLinear`, `scaleOrdinal`, `axisLeft`, `axisBottom`, and a reusable chart function with setter methods. The chart redraws every three seconds, alternating its x-axis between age and BMI, while the y-axis remains fixed on charges. Data comes from a CSV hosted on GitHub Gist, and the rendering uses SVG circles with opacity and transitions between axis configurations.

AI-generated description