How to manipulate Canvas elements: Difference between revisions

Jump to navigation Jump to search
Line 193: Line 193:
   var yValues = [];
   var yValues = [];
   for(var i=0;i<460;i+=4) append(yValues, 30*math.sin(i*D2R));
   for(var i=0;i<460;i+=4) append(yValues, 30*math.sin(i*D2R));
   canvas.plot2D.hzLine(myGroup, [10,100],175,blue);
   var xAxis = canvas.plot2D.hzLine(myGroup, [10,100],175,blue);
   canvas.plot2D.vtLine(myGroup, [15,180],-175,blue);
   var yAxis = canvas.plot2D.vtLine(myGroup, [15,180],-175,blue);
   canvas.plot2D.graphic(myGroup, yValues,,[15,100],red);
   var graph = canvas.plot2D.graphic(myGroup, yValues,,[15,100],red);


</syntaxhighlight>
</syntaxhighlight>
|| [[File:Plot2D,graphic.png|thumb]]
|| [[File:Plot2D,graphic.png|thumb]]
<hr/>
<hr/>

Navigation menu