Data Science · Ebook
Matplotlib: Visualizing Data in Python
by Shriira Press
A comprehensive, self-contained guide to Matplotlib, the foundational plotting library of the Python scientific and data ecosystem — the tool that turns arrays of numbers into figures you can see, reason about, and publish. Nearly every chart in a Python data-science or machine-learning workflow is drawn by Matplotlib (directly, or through libraries built on it). This book teaches it from first principles: the Figure/Axes architecture and the two APIs, the full catalog of plot types, customization and layout, images and colormaps, themes, 3D and animation, the ecosystem (seaborn and friends), and the craft of making figures that are clear, honest, and publication-ready. It blends intuition, the concepts behind the API, and runnable code.
Contents
- 1Preface
- 2Chapter 1 — What Is Matplotlib?
- 3Chapter 2 — The Anatomy of a Figure: Figure, Axes, and the Two APIs
- 4Chapter 3 — Your First Plots: Line, Scatter, and Bar
- 5Chapter 4 — Statistical and Distribution Plots
- 6Chapter 5 — Plotting from Data: NumPy and pandas
- 7Chapter 6 — Images, Colormaps, and Heatmaps
- 8Chapter 7 — Styling Plots: Colors, Lines, Markers, and Text
- 9Chapter 8 — Axes, Scales, Ticks, and Dates
- 10Chapter 9 — Subplots and Layout
- 11Chapter 10 — Themes, Styles, and rcParams
- 12Chapter 11 — 3D, Animation, and Interactivity
- 13Chapter 12 — The Ecosystem: seaborn, pandas, and beyond
- 14Chapter 13 — Publication, Production, and Best Practices
- 15Appendix A — Glossary and API Quick Reference
- 16Appendix B — Further Reading and Resources
