class_docstr: Displays an isocurve of a 2D scalar array.
  
  Parameters
  ----------
  data : ndarray | None
      2D scalar array.
  levels : ndarray, shape (Nlev,) | None
      The levels at which the isocurve is constructed from "*data*".
  color_lev : Color, 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).
  clim : tuple
      (min, max) limits to apply when mapping level values through a
      colormap.
  **kwargs : dict
      Keyword arguments to pass to `LineVisual`.
class_docstr_tok: ["Displays","an","isocurve","of","a","2D","scalar","array",".","Parameters","--","--","--","--","--","data",":","ndarray","|","None","2D","scalar","array",".","levels",":","ndarray",",","shape","(","Nlev",",",")","|","None","The","levels","at","which","the","isocurve","is","constructed","from","``","*","data","*","''",".","color_lev",":","Color",",","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",")",".","clim",":","tuple","(","min",",","max",")","limits","to","apply","when","mapping","level","values","through","a","colormap",".","*","*","kwargs",":","dict","Keyword","arguments","to","pass","to","`","LineVisual","`","."]
docstr: Set the scalar array data
  
  Parameters
  ----------
  data : ndarray
      A 2D array of scalar values. The isocurve is constructed to show
      all locations in the scalar field equal to ``self.levels``.
docstr_tok: ["Set","the","scalar","array","data","Parameters","--","--","--","--","--","data",":","ndarray","A","2D","array","of","scalar","values",".","The","isocurve","is","constructed","to","show","all","locations","in","the","scalar","field","equal","to","``","self.levels","``","."]
code: def set_data(self, data):
      """Set the scalar array data
  
      Parameters
      ----------
      data : ndarray
          A 2D array of scalar values. The isocurve is constructed to show
          all locations in the scalar field equal to ``self.levels``.
      """
      self._data = data
  
      if self._clim is None:
          self._clim = (data.min(), data.max())
  
      # sanity check,
      # should we raise an error here, since no isolines can be drawn?
      # for now, _prepare_draw returns False if no isoline can be drawn
      if self._data.min() != self._data.max():
          self._data_is_uniform = False
      else:
          self._data_is_uniform = True
  
      self._need_recompute = True
      self.update()
  
file_path: vispy/vispy/visuals/isocurve.py
imports: from __future__ import division
  import numpy
  from .line import LineVisual
  from ..color import ColorArray
  from ..color.colormap import _normalize, get_colormap
  from ..geometry.isocurve import isocurve
label_desc: Use image node_id 6 for calling the IsocurveVisual obj's underlying member method code with example usage: obj.set_data(data) without return types