Block 33: Plot Customization & Styling
Make plots professional and readable.
Concepts
- Figure size: figsize=(w,h)
- Fonts, tick labels, rotation
- Grid lines: ax.grid()
- Color maps and custom colors
- plt.style.use()
Code Examples
See exercise below.
Exercise
Recreate yesterday's bar chart with improved styling: custom colors, rotated x labels, grid lines. Save your best plot as a PNG at 150 DPI.
Homework
Find the 3 matplotlib styles you like best by running plt.style.available and comparing them.