Skip to main content
100%

BMI by Age

✓ Published0🌍 Public
Cchsaisriharsha@gmail.com
Last edited Jun 14, 2023
Created on Jun 14, 2023
Forked from Hello VizHub

This bar chart displays the average body mass index (BMI) across different ages from a CSV dataset, with age on the x-axis and average BMI on the y-axis. The code uses d3.csv to load data, d3.bin to group ages into bins, and d3.scaleLinear, d3.axisBottom, and d3.axisLeft to render the axes. The chart is drawn as SVG rectangles with a light blue fill, and the BMI is calculated from weight and height fields using the formula (weight/height²)*703.

AI-generated description

An example showing the capabilities of VizHub:

  • Loads D3 via UNPKG.
  • Demonstrates use of import from "d3".
  • Demonstrates use of import from local ES6 modules.
MIT Licensed

Similar vizzes