Download Print this page

HP 30S Instruction Manual page 3

Advertisement

hp calculators
HP 30S Statistics – Linear Regression
x
y
Find the linear regression line and the correlation coefficient for this data.
Solution:
First of all, we have to enter the given data, which is really easy on the HP 30S. Simply pressing a
makes your calculator prompt you for the first value displaying "x
data by pressing:
2?3?1?1?6?5?3?5?7?7?6?8?9?8.5
?
Data pairs are entered in order, the x values first. Notice that values are actually entered by pressing the ?
key, not the y key. This is because you may wish to calculate a value first (e.g. A y+ B % ANS y)
– keep in mind that the history stack (i.e. a log of past calculations) is not available in STAT mode, but the
ANS variable can be used, and the most recent calculation can be retrieved to be edited. Correcting data is
as easy as using the & and ? keys to display the wrong value and change it. The new value replaces the
old one: you need not press oto clear the entry line.
Once all the values have been entered, results can be displayed by pressing b. This displays a menu
with seventeen variables. Select the desired result using the < and the @ keys. Values appear in the
result line. Pressing yputs the selected variable (its name, not its value) into the entry line for further
calculations. This menu works much like the CONST menu.
Answer:
Expressed to two decimal digits, a = 1.22 and b = 0.85, therefore the regression line is:
=
+
y
.
1
22
that it is quite a good fit since r is close to 1. However, exactly how far away from this value the correlation
can be and the equation still be considered a good predictor is certainly a matter of debate.
Example 2: If the engineer adds 4 grams of the chemical, what will be the concentration in the final product?
Solution:
Predicted values can be easily calculated using the regression line, but the quickest way is to use the
STATVAR menu again. Press b, select
blinking cursor placed on the right parenthesis.
.
returns
1
22
but not on your calculator). Enter the given x value: 4and press yto calculate the predicted
concentration.
=
( ' y 4
)
Answer:
4.63. In many textbooks
concentration may well be different.: the regression line is just a mathematical model of the reality.
Example 3: In order to obtain a concentration of 10.5, how much chemical should she add?
Solution:
Once again press b but select
' x
returns
amount of chemical.
hp calculators
2
1
3
1
.
x
. The correlation coefficient, is 0.91, which means that the correlation is positive and
0
85
+
.
x
(remember that these numbers are shown to two decimal digits in this document,
0
85
' y
' x
y −
a
. Enter the given y value: 10.5 and press yto calculate the estimated
b
6
3
5
5
' y
and press y. The entry line now reads
' y
returns a predicted y value given an x value, that is,
y ˆ
is written as
. It is important to understand that the actual
this time, and press yto put this function into the entry line.
- 3 -
7
6
9
7
8
8.5
=" in the entry line. Let's now enter the
1
HP 30S Statistics – Linear Regression - Version 1.0
y
) ( '
with the

Advertisement

loading