7.17. Summary¶
In this chapter, you learned how to create plots using Python and Matplotlib. You learned what Matplotlib is and why problem solvers should learn how to use Matplotlib. Matplotlib installation was shown at the start of the chapter. Then, you learned how to build line plots and save plots as image files. You learned how to customize plots by including axis label, titles, and legends on your plots. You also learned how to add annotations to plots.
The types of plots detailed in this chapter are shown in the table below.
Chart Type |
Matplotlib method |
---|---|
line plot |
|
multi-line plot |
|
bar graph |
|
pie chart |
|
bar graphs with error bars |
|
line plot with error bars |
|
histogram |
|
box plot |
|
violin plot |
|
scatter plot |
|
plot annotations |
|
subplots |
|
plot styles |
|
2D contour plot |
|
2D filled contour plot |
|
color bars |
|
color maps |
|
quiver plot |
|
stream plot |
|
3D surface plot |
|
3D wireframe plot |
|
7.17.1. Key Terms and Concepts¶
plot
dpi
invoke
library
parameters
RGBA
object
attribute
object-oriented programming
method
image resolution
error bars
box plot
violin plot
histogram
annotation
reference frame
contour plot
quiver plot
stream plot
gradient
field
wire frame plot
projection
7.17.2. Additional Resources¶
Matplotlib official documentation: https://matplotlib.org/contents.html
Matplotlib summary notebook on Kaggle: https://www.kaggle.com/grroverpr/matplotlib-plotting-guide/notebook
Python Plotting With Matplotlib (Guide) on Real Python: https://realpython.com/python-matplotlib-guide/#why-can-matplotlib-be-confusing
Python For Data Science: Matplotlib Cheat Sheet from DataCamp: https://s3.amazonaws.com/assets.datacamp.com/blog_assets/Python_Matplotlib_Cheat_Sheet.pdf