yt.visualization.plot_window.PlotWindow.set_colorbar_label

PlotWindow.set_colorbar_label(*args, **kwargs)

Sets the colorbar label.

Parameters:

field: str or tuple :

The name of the field to modify the label for.

label: str :

The new label

>>> plot.set_colorbar_label(“density”, “Dark Matter Density (g cm$^{-3}$)”) :