How to Embed Matplotlib Figures in Tkinter / PyQt GUIs
Embed Matplotlib figures in Tkinter and PyQt applications with FigureCanvasTkAgg and FigureCanvasQTAgg.
Embed Matplotlib figures in Tkinter and PyQt applications with FigureCanvasTkAgg and FigureCanvasQTAgg.
Use a custom font, like one downloaded from Google Fonts, in Matplotlib charts instead of the default DejaVu Sans.
Draw a population pyramid in Python with Matplotlib using mirrored horizontal bar charts.
A practical Matplotlib workflow for creating animations and exporting them as GIF or MP4 files.
Make a donut chart in Matplotlib and add a centered label with ax.text.
Build a Pareto chart in Matplotlib, combining a sorted bar chart with a cumulative percentage line to visualize the 80/20 rule.
Build a slope chart in Matplotlib for comparing a value across two time points, including label decluttering and highlighting a category.
Build a correlation matrix heatmap in Matplotlib with rich annotations, including significance stars and a properly zero-centered color scale.
Highlight a date range or a rectangular area in Matplotlib plots with axvspan and axhspan.
Add shaded areas and true vertical gradient fills under Matplotlib line plots using fill_between and imshow with a clip path.
Create continuous and discrete custom colormaps in Matplotlib from a list of hex colors and apply them to scatter plots and heatmaps.
Color each bar in a Matplotlib bar chart individually — by threshold, colormap gradient, or to highlight a specific value.
Switch the look of any Matplotlib chart in one line with built-in style sheets like ggplot, dark_background, seaborn, and fivethirtyeight.
Export Matplotlib plots as PNGs with a fully or partially transparent background using savefig and patch alpha settings.
How to use hex color codes and custom RGB tuples to give Matplotlib charts a polished, on-brand look.
Use LaTeX math notation in Matplotlib titles, axis labels, legends, and annotations with raw strings and mathtext.
Quick guide to styling the main title, subtitle, and footnote of a Matplotlib figure.
Step-by-step guide to drawing straight and curved callout arrows using plt.annotate in Matplotlib.
Quick guide on adding descriptive text labels and callout annotations to data points in Matplotlib.
Quick guide on formatting a Matplotlib legend into multiple columns using the ncol parameter.