Example/CanvasCurveFitting - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim

Home : Support : Online Help : Example/CanvasCurveFitting

Curve Fitting Canvas Application Example 


In this example the user is asked to click on a plot to add points.  When 2 or more points are set, the application will find a polynomial curve fit approximation and draw that on the plot too.

The complete application source code is available here for you to inspect and modify.  It uses the
Canvas package to describe the interface, and a ScriptButton with a onclick action and a State element to store hidden values.  An important point in this example is the use of the 'include' option to make sure the 'myView' variable is included into the button action code. 

Embedded component

> ShareCanvas(cv);


> ShowCanvas(cv,entrybox=false);

Embedded component

Embedded component
Embedded componentEmbedded component


Next Steps 


Return to DocumentTools[Canvas] Overview Page