Task 9
✓ Published0🌍 Public
This visualization displays the top 20 Netflix TV shows and movies as a pie chart, with each slice labeled by its count and accompanied by a color-coded legend. It loads data from a GitHub-hosted CSV file using d3.csv, then sorts and filters it to show only the top entries. The chart uses d3.pie to generate arc data and d3.arc to draw SVG paths, with d3.scaleOrdinal assigning colors to slices. Text labels are positioned using arc.centroid, while the legend is built with SVG rect elements and text in a d3.selectAll pattern.
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