Chapter 10

Getting a Crash Course in MatPlotLib


Bullet Creating a basic graph

Bullet Adding measurement lines to your graph

Bullet Dressing your graph up with styles and color

Bullet Documenting your graph with labels, annotations, and legends

Most people visualize information better when they see it in graphic, versus textual, format. Graphics help people see relationships and make comparisons with greater ease. Even if you can deal with the abstraction of textual data with ease, performing data analysis is all about communication. Unless you can communicate your ideas to other people, the act of obtaining, shaping, and analyzing the data has little value beyond your own personal needs. Fortunately, Python makes the task of converting your textual data into graphics relatively easy using MatPlotLib, which is actually a simulation of the MATLAB application. You can see a comparison of the two at

Tip If you already know how to use MATLAB (see MATLAB For Dummies, ...

Get Python for Data Science For Dummies, 2nd Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.