Field plotting
- stride.plotting.plot_scalar_fields.plot_scalar_field(field, data_range=(None, None), origin=None, limit=None, axis=None, palette='viridis', title=None, **kwargs)[source]
Utility function to plot a scalar field using matplotib (2D) or MayaVi (3D).
- Parameters
field (ScalarField or VectorField) – Field to be plotted
data_range (tuple, optional) – Range of the data, defaults to (min(field), max(field)).
origin (tuple, optional) – Origin of the axes of the plot, defaults to zero.
limit (tuple, optional) – Extent of the axes of the plot, defaults to the spatial extent.
axis (MayaVi axis, optional) – Axis in which to make the plotting, defaults to new empty one.
palette (str, optional) – Palette to use in the plotting, defaults to plasma.
title (str, optional) – Figure title, defaults to empty title.
- Returns
Generated matplotlib or MayaVi figure
- Return type
matplotlib or MayaVi figure
- stride.plotting.plot_vector_fields.plot_vector_field(field, data_range=(None, None), origin=None, limit=None, axis=None, palette='viridis', title=None, **kwargs)[source]
Utility function to plot a vector field using matplotib (2D) or MayaVi (3D).
- Parameters
field (VectorField) – Field to be plotted
data_range (tuple, optional) – Range of the data, defaults to (min(field), max(field)).
origin (tuple, optional) – Origin of the axes of the plot, defaults to zero.
limit (tuple, optional) – Extent of the axes of the plot, defaults to the spatial extent.
axis (MayaVi axis, optional) – Axis in which to make the plotting, defaults to new empty one.
palette (str, optional) – Palette to use in the plotting, defaults to plasma.
title (str, optional) – Figure title, defaults to empty title.
- Returns
Generated matplotlib or MayaVi figure
- Return type
matplotlib or MayaVi figure