Skip to main content
Ctrl+K
This website is for version 5. You can find the documentation for version 4 here.
Logo image

Vega-Altair

Site Navigation

  • Getting Started
  • User Guide
  • Examples
  • API
  • Resources
  • Release Notes

Site Navigation

  • Getting Started
  • User Guide
  • Examples
  • API
  • Resources
  • Release Notes

Section Navigation

Examples

  • Gallery
  • Tutorials
    • Exploring Seattle Weather
  • Example Gallery

Example Gallery#

This gallery contains a selection of examples of the plots Altair can create. Some may seem fairly complicated at first glance, but they are built by combining a simple set of declarative building blocks.

Many draw upon sample datasets compiled by the Vega project. To access them yourself, install vega_datasets.

python -m pip install vega_datasets

If you can’t find the plots you are looking for here, make sure to check out the Related Projects section, which has links to packages for making e.g. network diagrams and animations.

Simple Charts#

Simple Bar Chart Simple Heatmap Simple Histogram Simple Line Chart Simple Scatter Plot with Tooltips Simple Stacked Area Chart Simple Strip Plot

Bar Charts#

Bar Chart with Highlighted Bar Bar Chart with Highlighted Segment Bar Chart with Labels Bar Chart with Line at Mean Bar Chart with Line on Dual Axis Bar Chart with Negative Values Bar Chart with Rolling Mean Bar Chart with Rounded Edges Bar and Tick Chart Calculating Percentage of Total Compact Trellis Grid of Bar Charts Diverging Stacked Bar Chart Grouped Bar Chart Grouped Bar Chart with Error Bars Grouped Bar Chart with xOffset Horizontal Bar Chart Horizontal Grouped Bar Chart Horizontal Stacked Bar Chart Layered Bar Chart Normalized Stacked Bar Chart Sorted Bar Chart Stacked Bar Chart Stacked Bar Chart with Sorted Segments Stacked Bar Chart with Text Overlay Trellis Stacked Bar Chart

Line Charts#

Bump Chart Filled Step Chart Line Chart with Cumulative Sum Line Chart with Custom Legend Line Chart with Datum Line Chart with Datum for Color Line Chart with Interpolation Line Chart with Last Value Labeled Line Chart with Layered Aggregates Line Chart with Logarithmic Scale Line Chart with Percent axis Line Chart with Point Markers Line Chart with Sequence Generator Line Chart with Stroked Point Markers Line Chart with Varying Size Multiple Series Line Chart Slope Graph Step Chart Window Rank Line Chart

Area Charts#

Area Chart with Gradient Horizon Graph Interval Selection Layered Area Chart Normalized Stacked Area Chart Streamgraph Trellis Area Chart Trellis Area Sort Chart

Circular Plots#

Donut Chart Pacman Chart Pie Chart Pie Chart with Labels Radial Chart

Scatter Plots#

Brushing Scatter Plot to Show Data on a Table Bubble Plot Connected Scatter Plot (Lines with Custom Paths) Multifeature Scatter Plot Scatter Matrix Scatter Plot with Href Scatter Plot with Minimap Scatter Plot with Rolling Mean Simple Scatter Plot with Labels Trellis Scatter Plot

Uncertainties And Trends#

Error Bars with Confidence Interval Error Bars with Standard Deviation Line Chart with Confidence Interval Band Polynomial Fit Plot with Regression Transform Scatter Plot with LOESS Lines Simple Scatter Plot with Errorbars

Distributions#

2D Histogram Heatmap 2D Histogram Scatter Plot Boxplot with Min/Max Whiskers Cumulative Count Chart Dot Dash Plot Empirical Cumulative Distribution Function Faceted Density Estimates Facetted Scatter Plot with Marginal Histograms Heat Lane Chart Histogram with Responsive Bins Histogram with a Global Mean Overlay Layered Histogram Quantile-Quantile Plot Ridgeline plot Stacked Density Estimates Strip Plot with Jitter Table Bubble Plot (Github Punch Card) Trellis Histogram Violin Plot

Tables#

Annual Weather Heatmap Hexbin Chart Lasagna Plot (Dense Time-Series Heatmap) Mosaic Chart with Labels Text over a Heatmap

Maps#

Choropleth Map Grouped Points with Proportional Symbols Map Point map Repeated Choropleth Map US Income by State: Wrapped Facet Wind Vector Map World Map World Projections

Interactive Charts#

Image Tooltip Interactive Average Interactive Chart with Cross-Highlight Interactive Crossfilter Interactive Legend Interactive Rectangular Brush Interactive Scatter Plot and Linked Layered Histogram Multi-Line Highlight Multi-Line Tooltip Multi-panel Scatter Plot with Linked Brushing Multiple Interactions Scatter Plot and Histogram with Interval Selection Selection Detail Selection Histogram Simple Interactive Colored Scatter Plot Slider Cutoff Using Selection Interval with mark_area

Advanced Calculations#

Becker's Barley Trellis Plot (Wrapped Facet) Candlestick Chart Comet Chart Gantt Chart Isotype Grid Isotype Visualization Isotype Visualization with Emoji Layered chart with Dual-Axis Normalized Parallel Coordinates Parallel Coordinates Ranged Dot Plot Sorted Error Bars showing Confidence Interval Stem and Leaf Plot Top K Items Top K Letters Top-K Plot with Others Waterfall Chart Wilkinson Dot Plot

Case Studies#

Anscombe's Quartet Atmospheric CO2 Concentration Becker's Barley Trellis Plot Connections Among U.S. Airports Interactive Dendrogram of Hierarchical Clustering Gapminder Bubble Plot Global Deaths from Natural Disasters Iowa's Renewable Energy Boom London Tube Lines One Dot Per Zipcode Population of Falkensee from 1875 to 2014 Pyramid Pie Chart Seattle Weather Interactive The U.S. Employment Crash During the Great Recession U.S. State Capitals Overlayed on a Map of the U.S US Population Pyramid Over Time US Population by Age and Sex US Population: Wrapped Facet Wheat and Wages

previous

Large Datasets

next

Exploring Seattle Weather

On this page
  • Simple Charts
  • Bar Charts
  • Line Charts
  • Area Charts
  • Circular Plots
  • Scatter Plots
  • Uncertainties And Trends
  • Distributions
  • Tables
  • Maps
  • Interactive Charts
  • Advanced Calculations
  • Case Studies

© Copyright 2016-2023, Vega-Altair Developers.

Created using Sphinx 6.2.1.

Built with the PyData Sphinx Theme 0.13.3.