Multiple Line plot with Dropdown
A dropdown menu controls the y-axis metric of a multi-line chart tracking London air quality from January 2010 to August 2018, using particulate matter and gas concentration data from the London Datastore. The visualization displays nine color-coded time series, one per year, with a legend on the right. Built with D3 v5, it uses `d3.nest` to group data by year, `d3.line` with `curveBasis` for smoothing, and `d3.scaleTime` for the x-axis. A custom `dropdownMenu` module handles user selection, triggering a 1.5-second `transition.attrTween` animation when switching metrics.
AI-generated descriptionKathleen Cachel
Data in this scatter plot is from from the Kings College London Air Quality Dataset in the London Datastore. The data is from January 2010 through August 2018.
</n> Inspiration from Curran and this Vis. This week I spent time munging the data and adding a dropdown menu.