Figure Tools

Figure layout, axes linking, interactive controls — the plumbing for good-looking multi-panel figures.

Layout

Task

Use

Lay out an M × N grid with controlled margins

figdesign()

Open a full-screen figure

fullfig()

Add panel labels (A, B, C, …)

letter_label()

Add a figure-level title/labels across subplots

outertitle(), outerlabels()

Merge multiple figures into one

mergefigures()

Prep a figure for print / page export

pagefig()

Find the most-square subplot grid for N panels

squarest_subplots()

Axes linking & limits

Task

Use

Link color axes across a set of axes

linkcaxes()

Link 3-D camera + xyz limits across axes

linkaxes3d()

Match X/Y limits across axes

equalize_axes()

Scale color limits to an inner percentile

climscale()

Set color limits manually

clims()

Colorbars & annotations

Task

Use

Add a colorbar that doesn’t resize the parent axes

colorbar_noresize()

Add a colorbar along the top

topcolorbar()

Draw a scale bar on an axis

scaleline()

Add a shadow / secondary axis

shadow_axis()

Split an axis into multiple panels

split_axis()

Interaction

Task

Use

Interactive scroll/zoom/pan with mouse + keyboard

scrollzoompan()

Capture user clicks on a figure

get_clicks()

Pop up a slice picker UI

slicepopup()

Zoom so content fills the axes

zoom_fill()

Build a stacked-plot control

stacked_plot()

Reference