813 Excel Functions
Linest produces a block of output without column headers or row
labels that identify the output. Excel’s Help provides a good explanation
of the meaning of the output; in the preceding picture, we have added in
the explanations.
Note the syntax of this function: Linest(y-range,x-range,constant,sta-
tistics). The y-range is the range of dependent variables, and the x-range
is the range of the independent variables. If constant is omitted (as in
this case) or set to True, then the regression is calculated normally; if
constant is set to False, then the intercept is forced to be zero. If statistics
is set to True (as in this case), then the range of statistics is calculated;
otherwise only the slope and intercept are calculated.
Individual items of this output can be accessed by using the function
Index discussed earlier. Suppose, for example, that we want to do a
simple t-test on the slope; this task requires us to divide the slope value
by its standard error.
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
BACDEFGHI
Linest output
slope intercept
Slope (also
=slope(D4:D13,C4:C13)
)
--
>
-0.0890 14.3285 <
--
Intercept
Standard error of slope
--
> 0.0148 0.8770 <
--
Standard error of intercept
R
2
(also
=Rsq(D4:D13,C4:C13)
)
--
>
0.8189 0.8117
<
--
Standard error of y values (also
=Steyx(D4:D13,C4:C13)
)
F statistic
--
> 36.1825 8 <
--
Degrees of freedom
SS
xy
= Slope*(summed product of observations from means)
--
>
23.8377 5.2705 <
--
SSE = Residual sum of squares
Slope -0.0890 <
--
=INDEX(LINEST(D4:D13,C4:C13,,1),1,1)
Intercept 14.3285 <
--
=INDEX(LINEST(D4:D13,C4:C13,,1),1,2)
R
2
0.8189 <
--
=INDEX(LINEST(D4:D13,C4:C13,,1),3,1)
Slope -0.0890 <
--
=INDEX(LINEST(D4:D13,C4:C13,,TRUE),1,1)
S.e. of slope 0.0148 <
--
=INDEX(LINEST(D4:D13,C4:C13,,TRUE),2,1)
t-statistic -6.0152 <
--
=C31/C32
J
33.6.3 Multiple Regressions
Linest can also be used to do a multiple regression, as in the following
illustration: