Fork me on GitHub
jsGraph

Contour plot v2

In the version 2, you should include the contour line minimums and maximums. This is an alternative to the forceMin and forceMax methods in the version 1.

Source code

var graphinstance = new Graph( domGraph );

var serie = graphinstance.newSerie( "serieTest", {}, "contour" )
  .setLabel( "My serie" )
  .autoAxis()
  .setData( {

    minX: -5,
    maxX: 5,
    minY: -5,
    maxY: 5,
    segments: contour

  } );

graphinstance.redraw();
graphinstance.drawSeries();