0Pricing
Python Academy · Lesson

Customizing Plots

Add titles, labels, and legends.

From Raw to Readable

A bare chart shows data but tells the reader little. Customization adds the context that turns a plot into a clear message: titles, axis labels, legends, ticks, and annotations.

All of these are methods on the axes object.

Titles

Give every axes a title with ax.set_title('Monthly Sales'). A figure-wide title uses fig.suptitle('Report').

The title should state what the chart shows, not just repeat the column name.

raw_label = 'sales_q1'
nice_title = raw_label.replace('_', ' ').title()
print('Title:', nice_title)

All lessons in this course

  1. Figures and Axes
  2. Line, Bar and Scatter Plots
  3. Customizing Plots
  4. Subplots and Layouts
← Back to Python Academy