Skip to main content
100%

Mental Health Survey Pie Chart Project Momentum

✓ Published1🌍 Public
JJoe Rozman
Last edited Oct 31, 2024
Created on Oct 31, 2024

This interactive pie chart explores mental health survey data, allowing users to select an attribute (such as academic year or gender) and a metric (like depression or anxiety) to visualize the average score across categories. The chart updates dynamically using D3’s pie and arc generators, with dropdown menus controlling the selections. Data is aggregated via rollups to compute mean values, and a color-coded legend displays each category’s label and average. The visualization uses the D3 library and is styled with custom CSS for the SVG and selector elements.

AI-generated description

An approximation of a line chart using D3.js!

Watch the video and study the code to learn about:

  • SVG Path Elements
  • fill, stroke, stroke-width
  • stroke-linecap, stroke-linejoin
  • Vanilla HTML SVG Paths
  • D3.line
  • AI Assist

See also:

Full Playlist: Constructing Visualizations

MIT Licensed

Similar vizzes