grains.dic.plot_strain¶
-
grains.dic.
plot_strain
(strain, minval=None, maxval=None, colorbar=True, label='')[source]¶ Plots a scalar strain field.
- Parameters
strain (ndarray) – Scalar strain field sampled on an m-by-n grid, given as a 2D numpy array.
minval, maxval (float, optional) – Set the color scaling for the image by fixing the values that map to the colormap color limits. If
minval
is not provided, the limit is determined from the minimum value of the data. Similarly formaxval
.colorbar (bool, optional) – If True, a horizontal colorbar is placed below the strain map. The default is True.
label (str, optional) – Label describing the strain field. LaTeX code is also accepted, e.g. r’$varepsilon_{yy}$’. If not given, no text is displayed.
- Returns
None
See also
Deprecated since version 1.1.0: This will be removed in 1.3.0. This function will be a static method of the
DIC
class. See also the deprecation warning ofDIC.plot_strain()
.