BMI by Age
✓ Published0🌍 Public
This example visualizes the relationship between age and average body mass index (BMI) using a binned bar chart. The code loads data from a CSV file, computes BMI values, and uses D3 v7's `scaleLinear`, `scaleTime`, `axisLeft`, `axisBottom`, and `bin` utilities to create the visualization. The bars are rendered as SVG rectangles, with the y-axis labeled "Average Body Mass Index" and the x-axis "Age". The chart includes customized tick styling and an overall title, demonstrating D3's data import and ES6 module usage.
AI-generated descriptionAn example showing the capabilities of VizHub:
- Loads D3 via UNPKG.
- Demonstrates use of
importfrom"d3". - Demonstrates use of
importfrom local ES6 modules.
MIT Licensed