Vega-Lite API
✓ Published1🌍 Public
This example demonstrates a stacked bar chart of country populations by religion, using the Vega-Lite API to construct the visualization declaratively. It fetches data from a CSV file via d3.csv, then renders the chart as SVG with vega and vega-lite, customizing axis and label styles through a config object. The bars are encoded with country on the x-axis, population on the y-axis, and religion determining color, with tooltips showing population values. The chart auto-fits to the browser window size.
AI-generated descriptionA visualization constructed using the vega-lite-api.
MIT Licensed