🌍 Public
Viewing a saved revision (read-only)
39c4977fb83b4112b1fbdf54b2e30ecd
Military spending
This chart visualizes military spending from 2001-2020 for major countries. Each colored line represents a country, with the x-axis showing time and the y-axis showing spending in US dollars. The visualization orders the lines by each country's final spending value to make comparisons easier. Built with D3 v5, the code uses `scaleTime`, `scaleLinear`, `scaleOrdinal`, `axisBottom`, `axisLeft`, and `line` to construct the SVG rendering. The data comes from a CSV file, and a color legend is rendered using a custom `colorLegend` function.
AI-generated description