Echoes of Detonations: Nuclear Weapons Tests

Visualization protocol

Timestamp

February 2024

Data Source

Organization: Our World in Data (Link)

Dataset & Metadata

Download Dataset (csv)


Protocol Actions
  1. Load Data:
    The dataset number-of-nuclear-weapons-tests.csv is imported into a Pandas DataFrame.
  2. Data Processing:
    The data is grouped by "Entity" (Country) to calculate the sum of tests per country. The Entities are then sorted in descending order by this total sum to define the visual stacking order.
  3. Visualization Layout:
    A stacked bar chart is initialized using Plotly Express with "Year" on the x-axis and "Number of nuclear weapons tests" on the y-axis. The bars are colored by "Entity".
  4. Chart Styling:
    The "plotly_dark" template is applied. The title is set to emphasize the "Echoes of Detonations" during the Cold War.
  5. Refinement:
    The layout is updated to stack bars, unified hover tooltips are enabled (showing totals for all countries in a given year), and axes are set to fixed ranges to prevent interaction issues in the embedded view.