Skip to content

How can I change plot data?

novikov-alexander edited this page Apr 21, 2016 · 1 revision

Simply pass new data to plot with a same name.

For example:

function getData(){
/*Some data generator*/
}

function polyline() { 
    var data = getData(); 
    InteractiveDataDisplay.asPlot('chart').polyline("p2", { x: data.x, y: data.y}); 
 
    setTimeout(polyline, 25); 
}