vispy.visuals.isocurve module

class vispy.visuals.isocurve.IsocurveVisual(data=None, levels=None, color_lev=None, clim=None, **kwargs)

Bases: vispy.visuals.line.line.LineVisual

Displays an isocurve of a 2D scalar array.

Parameters
datandarray | None

2D scalar array.

levelsndarray, shape (Nlev,) | None

The levels at which the isocurve is constructed from “data”.

color_levColor, colormap name, tuple, list or array

The color to use when drawing the line. If a list is given, it must be of shape (Nlev), if an array is given, it must be of shape (Nlev, …). and provide one color per level (rgba, colorname).

climtuple

(min, max) limits to apply when mapping level values through a colormap.

**kwargsdict

Keyword arguments to pass to LineVisual.

property color
property levels

The threshold at which the isocurve is constructed from the 2D data.

set_data(data)

Set the scalar array data

Parameters
datandarray

A 2D array of scalar values. The isocurve is constructed to show all locations in the scalar field equal to self.levels.