matshow
- mdtools.plot.matshow(ax, z, cax=None, xlabel='$x$', ylabel='$y$', cbarlabel='$z$', **kwargs)[source]
Plot a two dimensional matrix as heatmap with
matplotlib.axes.Axes.matshow()
.Deprecated since version 0.0.0.dev2: Use
mdtools.plot.matshow_new()
instead.- Parameters:
ax (
matplotlib.axes.Axes
) – The axes to draw to.z (
array_like
) – 2-dimensional array. Note: The grid orientation follows the standard matrix convention, i.e. an array z with shape(nrows, ncolumns)
is plotted with the column number as x and the row number as y.cax (
matplotlib.axes.Axes
, optional) – The axes to put the colorbar in.xlabel (
str
, optional) – Label for the x-axis.ylabel (
str
, optional) – Label for the y-axis.cbarlabel (
str
, optional) – Label for the colorbar.kwargs (
dict
, optional) – Keyword arguments to pass tomatplotlib.axes.Axes.matshow()
. See there for possible keyword arguments.
- Returns:
heatmap (
matplotlib.image.AxesImage
) – Amatplotlib.image.AxesImage
.