A picture is worth a thousand words, and with Python’smatplotlib library, it fortunately takes far less than a thousand words of code to create a production-quality graphic.
However,matplotlib is also a massive library, and getting a plot to look just right is often achieved through trial and error. Using one-liners to generate basic plots inmatplotlib is relatively simple, but skillfully commanding the remaining 98% of the library can be daunting.
In thisbeginner-friendly course, you’ll learn about plotting in Python withmatplotlib by looking at the theory and following along with practical examples. While learning by example can be tremendously insightful, it helps to have even just a surface-level understanding of the library’s inner workings and layout as well.
By the end of this course, you’ll:
matplotlibplt.subplots()matplotlibpandas andmatplotlibThis course assumes you know a tiny bit of NumPy. You’ll mainly use thenumpy.random module to generate “toy” data, drawing samples from different statistical distributions. If you don’t already havematplotlib installed, see thedocumentation for a walkthrough before proceeding.
What’s Included:
Related Learning Paths:
14 Lessons 1h 14m
AboutAustin Cepalia
Austin is a video tutorial author at Real Python. He graduated with a BS in CS from Rochester Institute of Technology in 2023, and now he writes software to support the semiconductor industry.
» More about AustinGlenn Lehman
Great learning experience!
I appreciated the advise to type out all the code. This allowed me to modify some of the items and see how this changed the output. Plus my typing skills allowed me to practice some basic debugging.
Thank you.
Get aPython Cheat Sheet (PDF) and learn the basics of Python, like working with data types, dictionaries, lists, and Python functions:
