39 matplotlib colorbar size
Adding colorbar without affecting the plotting area size. #15010 Aug 8, 2019 · x = np.random.normal(512, 112, 240) y = np.random.normal(0.5, 0.1, 240) fig, ax = plt.subplots(figsize=(10,5)) sc = ax.scatter(x,y, c=y) cax = make_square_axes_with_colorbar(ax, size=1, pad=1) fig.colorbar(sc, cax=cax); fig.savefig('figtest.png') fig.savefig('figtest.pdf') Colorbar — Matplotlib 3.7.1 documentation Controlling the position and size of colorbars with Inset Axes; Per-row or per-column colorbars; Axes with a fixed physical size; Setting a fixed aspect on ImageGrid cells; Inset locator demo; Inset locator demo 2; Make room for ylabel using axes_grid; Parasite Simple; Parasite Simple2; Scatter Histogram (Locatable Axes) Simple Anchored Artists ...
python - height of colorbar (matplotlib) - Stack Overflow May 20, 2018 · I know that we can adjust the size of colorbar with divider = make_axes_locatable (ax) cax = divider.append_axes ("right", size="3%",...