Python Data Visualization Transcripts
Chapter: Altair
Lecture: Vega lite

Login or purchase this course to watch this video and the rest of the course contents.
0:00 I'm gonna go through a little bit of what altair does behind the scenes because I think it will help you understand how to use altair most effectively.
0:08 And when we talk about installing some of the packages and other ways that altair works it will all make a little more sense.
0:16 Here's some simple code that generates an altair scatter plot and I'll go into it a little bit more detail to explain what happens.
0:24 But behind the scenes, after you create this code,
0:27 the altair package then converts this into a Json representation of your visualization using the vega
0:34 lite spec. And you can look at this specifications and see that a lot of the information that you pass in,
0:41 that python code gets translated into a pretty much 1 to 1 mapping in to the specification. Once that specification is complete,
0:49 it calls the javascript library to render the visualization. So all of this happens behind the scenes. And like I said, as you start to get into this,
0:59 it is helpful to understand what the process is and as you start to troubleshoot and figure out how to get your data to work,
1:07 it's useful to understand the underlying vega lite specs so you can reference that if you need to for more complex visualizations.

Talk Python's Mastodon Michael Kennedy's Mastodon