02Jmodellingcpda

= **Modelling and Regression on the Classpad** =

CAS calculators can perform regression for a number of different curves. We will use Linear, Quadratic and Cubic Regression.


 * Example 1 **

Use the Classpad to find the best model (equation) for the following data:




 * Go to the ** Statistics ** Page.
 * Enter the x values into List1
 * and the y values into List2


 * Tap the left icon to draw the graph.


 * If the graph doesn’t draw automatically, you may need to click in the table area then go to the ** SetGraph ** menu, select ** Settings **, then give it the following shown on the right:


 * Looking at the graph we can see that the graph curves upwards so it is probably a quadratic or cubic.


 * For this demonstration, I will start by doing a __ Linear Regression __.


 * Click in the table area then go to Calc menu and select Linear Reg.


 * You should get a screen like the one shown here:


 * XList and YList should match the lists where you entered your data.


 * If you set Copy Formula away from OFF you can store the resulting regression equation in Y1 (or Y2, etc)


 * Select OK and you should get a screen like the one shown here:

... ... ... ... y = 10.96x – 4.24
 * Using the values of ** a ** and ** b ** that are supplied, we get:


 * This is the linear regression equation or the “line of best fit.”


 * I have circled the r 2 value on the Linear Regression screen.


 * The r 2 value is a measure of how closely the line fits the data. The r 2 values vary from 0 to 1 where:
 * 0 means the data bears no relationship to the line
 * more than 0.9 means a strong correlation exists
 * 1 means a perfect fit – every data point is on the line.

media type="custom" key="7948374" media type="custom" key="7948384" align="right" media type="custom" key="7948392"
 * The r 2 value of 0.92 shown here is pretty good.
 * But looking at the graph suggests a quadratic or cubic function might be better.
 * Repeating the process with Quadratic Regression and Cubic Regression gives the following results:

media type="custom" key="7948436"

media type="custom" key="7948440"

media type="custom" key="7948450"

media type="custom" key="7948454"

media type="custom" key="7948458"

media type="custom" key="7948464"

media type="custom" key="7948466"


 * Quadratic Regression:**

... ... y = 2.20x 2 – 0.05x + 3.10

... ... r 2 = 0.999993


 * Cubic Regression:**

... ... y = 0.005x 3 +2.17x 2 – 0.01x + 3.08

... ... r 2 = 0.999994

We can see that both the Quadratic and Cubic Regression Lines are effectively a perfect fit.

Since the cubic regression has an x 3 term coefficient of less than 0.005, we can use the Quadratic Regression for all practical purposes.

Go To Example 2 Go to top of page: flat