Chapter 16. Visualizing Data
The previous chapters have given you all the tools you need to transform raw data into a polished DataFrame. But how do you turn such a DataFrame into something insightful?
One way is through data visualization, and Python provides a plethora of packages for that. Packages include Matplotlib for low-level plotting, hvPlot for quick visualizations, Bokeh for interactive graphs, plotnine for leveraging the grammar of graphics in Python, and Altair for using the built-in plotting capabilities of Polars. Figure 16-1 gives an impression of Python’s elaborate data visualization landscape.
This is both a blessing and a curse, because it’s likely there’s a package that fits your needs, but it’s challenging to choose the right package. Moreover, each package comes with its own set of features, assumptions, and pitfalls.
Data visualization isn’t just about making pretty pictures; it’s a fundamental part of data science. By transforming a DataFrame into graphical form, you improve your ability to understand trends, spot outliers, and tell stories that can influence decision making. Effective data visualizations clarify the obscure and simplify the complicated, making your data more accessible.
Figure 16-1. Python’s data visualization landscape (adapted, with permission, from the original by Jake VanderPlas)
A Couple of Disclaimers
Data visualization is an extensive ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access