The subplot function provides a method for arranging multiple Plotly plots in a single view. Discover how to create subplots with Plotly.
- [Instructor] So far we've focused on outputting … a single standalone plot in this course. … Now it's time to introduce subplots … as a way to include multiple plots in the same output. … These plots can be the same plot type and share an axis, … or they can even be entirely different plot types … arranged in a grid outline. … This is a great method to employ … when you want to package multiple plots together … to tell a more comprehensive story. … Subplots themselves are only supported … by plotly.graph_objects. … So first, we should cover a similar concept … in plotly.express, known as facet plots. … Before we do, let's import the gapminder data set … for the year of 2007 and create a scatter plot. … Now let's say we wanted to create a series of plots, … one for each continent. … To do this, we'll add facet column … and set it equal to continent. … Hey, that's pretty cool. … One plot per continent, all with the shared y-axis. … Now, perhaps you want these plots … to wrap to another row at some point. …
This course was created by Madecraft. We are pleased to host this training in our library.