From the course: More Python Tips, Tricks, and Techniques for Data Science
Unlock the full course today
Join today to access over 22,600 courses taught by industry experts or purchase this course individually.
Multiple subplots - Python Tutorial
From the course: More Python Tips, Tricks, and Techniques for Data Science
Multiple subplots
- [Instructor] Sometimes it is helpful to compare different plots of data side by side. To avail this Matplotlib has the concept of subplots, that is, grouping of smaller axes that can exist together within a single figure. These subplots might be in sets or grids of plots or other complicated layouts. So in this video, we'll explore different methods of creating subplots using matplotlib. So first off, we have imported the matplotlib and numpy libraries. And then we're going to look at very simple method of creating a subplot using the axes method. So we're going to simply create an inset axes inside another axes. So, first off I have the axis one, which is a simple axis. Now I'm going to specify another axes inside the axes one by specifying the X and Y coordinates 0.65, 0.65 then 0.2 and 0.2. So all these values. So this is creating an inset at the top right corner of axes one by setting the X and Y…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.