Post Reply 
(50g) Working Multiple linear regression in English
04-16-2022, 01:24 PM (This post was last modified: 04-16-2022 01:32 PM by Gil.)
Post: #7
RE: (50g) Working Multiple linear regression in English
Suppose the Production P is a function of Labour T & invested Capital C.

P=f(T, C).

Let's call these variables P61, T61 and C61 like in DATA /DODGE Directory.

These variables should be found on pages 3.5, 3.3 & 3.4 of DODGE Directory.

Here they are reproduced in Matrix Form as they have to be saved in the DATA /DODGE Directory.

{P .61:
[[ 60 ]
[ 120 ]
[ 190 ]
[ 250 ]
[ 300 ]
[ 360 ]
[ 380 ]
[ 430 ]
[ 440 ]]

T.61:
[[ 1100 ]
[ 1200 ]
[ 1430 ]
[ 1500 ]
[ 1520 ]
[ 1620 ]
[ 1800 ]
[ 1820 ]
[ 1800 ]]

C.61:
[[ 300 ]
[ 400 ]
[ 420 ]
[ 400 ]
[ 510 ]
[ 590 ]
[ 600 ]
[ 630 ]
[ 610 ]]

Write now {1 T61 C61 P61}
and press ENTER.

Note:
- Use brackets
- Put the number 1 as the first element of the list if you want the normal model with a constant (don't put that number 1 if you want a special model without the constant)
- Put all the explaining, independent variables in the list, in the order you wish
- Put always the explained, dependent variable at the end of that list

Press the program C.OK, which has to be present in the working file DATA/DODGE.

Note
This program C.OK will
- show the path where the data come from
{ 1 T.61 C.61 P.61 { DATA DODGE } }
- and put you back to the main menu

Now you can press
C.REG (B-key)

Note
- C with a dot stands here (and everywhere) for calculation.
- Suppose you see PROBbeta (Page 6.6 in the main directory) and ask yourself how it was calculated (in other words, you look for its "definition" here),then do:
'C.PROBbeta' ENTER RCL.

What you get is a very large Matrix

[[ 'YP.61' 'ßižŒ5%' 'ßi¦Values' 'T.TAB2.44691185114' 'Sߏ' 'PROBߏ' 'VIF1¦With.Const1' 'VIF.WITH.CONST1' 'CONDIT.IND' ]
[ 1 'OK' -437.713632901 -7.55577881008 57.9309749403 2.78970456598E-4 '¯' '¯' '¯' ]
[ 'T.61' 'OK' .336530289395 3.75321467363 .089664545905 9.47384870108E-3 8.19773451775 '—XY¦?Not.Calc' '—XY¦?Not.Calc' ]
[ 'C.61?' 'ߍ0' .410015695781 2.09038685644 .196143452834 .081554631945 8.19773451781 '—XY¦?Not.Calc' '—XY¦?Not.Calc' ]
[ '¯' '¯' '¯' '¯' '¯' '¯' '¯' '¯' '¯' ]
[ 'R2' '¯' .978404282436 'R2ADJ' .971205709914 'VARIAT.COEF¦%¦' 8.20725553662 '¯' '¯' ]]

To enter the RESUL(T) Matrix:
Have the requested Matrix in the stack
And press the "Down-Arrow"-key (just above the SYMB-Key).

The beta values are in the 3rd column.
The probability associated in the 6th column .
The name of the independent variables in row 3 & 4, column 1
The name of the depend variable Y, here P61, in row 1, column 1.

So betas are
[[ -437.713632901 ]
[ .336530289395 ]
[ .410015695781 ]]

Note
If, afterwards, you want to get back only the betas, write:
Alpha-key
Redshift-key
B-key
ENTER

Suppose you cleared your screen and want to get back your results:
Press RESUL(ts) key (D-key).

Suppose you are not sure from which file the given variables come from.
Then press LIST0.. key (C-key).

Note
The full name of LIST0 is
LIST0.INPUT.REG.LAST

Now about the F values
Press the ANOVA-KEY (E-key), which is just in the right of RESUL (key).

Note
Before executing ANOVA (key), you must, of course, have run C.REG.

Result of Anova will give the following:

[[ 'All.ßi¦0?†No†' '°lib' '…C' 'µC' 'F.ANOVAPROB' ]
[ 'REGP¯1' '3¯1' 144695.122156 72347.561078 (135.916430532,1.00717031607E-5) ]
[ '“N¯P' '9¯3' 3193.76667537 532.294445895 'FŒ5%žP¯1žN¯P' ]
[ 'TOTN¯1' '9¯1' 147888.888889 18486.1111111 5.14325284979 ]]

To enter the ANOVA Matrix:
Have the requested Matrix in the stack
And press the "Down-Arrow"-key (just above the SYMB-Key).

Explanations for ANOVA output:
2nd row, 5th column: Eff F value calc. from your data =135.9
2nd row, 5th column: p value associated=0.00001
Just above, row 1/col 5: expl names F/p

4th row, 5th column: F theorical from tables=5.14
Just above, row 4/col: expl how to get this value from a book.

As the F Eff statistics =135.9
>
Ftable <alpha-level=5%,p-1=2,n-p=6> = 5.14,
we reject, with the alpha-level = 5%, the Ho hypothesis that beta1=beta2=0.

Work out this
Please try and work out this example and report me please how clear or unclear it all seems to you.

In fact, I gave priority to the results description.

Regards,
Gil
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: (50g) Working Multiple linear regression in English - Gil - 04-16-2022 01:24 PM



User(s) browsing this thread: 1 Guest(s)