Skip to main content
100%

Fork of Stacked Bar Charts

✓ Published0🌍 Public
Hhi4u2qzy@gmail.com
Last edited Oct 26, 2023
Created on Oct 17, 2023

This stacked bar chart visualizes the 2010 estimated religion breakdowns of the world’s 20 most populous countries, with each bar segmented by religious affiliation. Users can reorder the bars by overall score or any of five component metrics (teaching, research, citations, industry income, international outlook) and sort ascending or descending. Hovering over a segment reveals a tooltip with the exact value and country name via d3.event, while selecting a legend item highlights that religion. The chart uses d3.stack, d3.scaleBand, and d3.axisBottom/Left, rendering as SVG, with data from Pew Research’s Global Religious Landscape.

AI-generated description

Stacked bar chart showing estimated religion breakdown.

Interactions:

  • Hover over the bars for tool tips.
  • Hover over the legend to highlight religions.

Based on an example from the tutorial Splitting Charts. Derived from the following examples published on bl.ocks.org:

Estimated 2010 religion breakdown of the most populous 20 countries.

Data is from The Global Religious Landscape by Pew Research, generated using this processing script.

TODO: Upgrade dependencies to latest D3 & friends.

MIT Licensed

Similar vizzes