Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

How to label your colorbar in contour plots?

i looked at the options of the contour_plot funciton and tried this:

enter code herecontour_plot(pic, (x,-1,1), (z,-1,1), region=region_to_include, contours= 30, plot_points=200, cmap=colormaps.jet, colorbar=True, axes_labels=['$x$ in [m]','$z$ in [m]'], legend_label=['Potential in $V$'])

but that does nto give any effect.

I want to put the unit of my plot there. how can i do that?

How to label your colorbar in contour plots?

i looked at the options of the contour_plot funciton and tried this:

enter code herecontour_plot(pic, (x,-1,1), (z,-1,1), region=region_to_include, contours= 30, plot_points=200, cmap=colormaps.jet, colorbar=True, axes_labels=['$x$ in [m]','$z$ in [m]'], legend_label=['Potential in $V$'])

$V$'])

but that does nto give any effect.

I want to put the unit of my plot there. how can i do that?