* OLS Model for Excess Stocks' Return
*
* Keywords:
* regression, ols, intercept, excess return, stock
*
* Description:
* We illustrate how to estimate Linear OLS Model for Excess Stocks' Return
* with and without an intercept
*
* Author(s):
* Skif Pankov
*
* Source:
* Damodar N. Gujarati and Dawn C. Porter, Basic Econometrics - 5th Edition
* McGraw-Hill International Edition, Chapter 6, Example 6.1 (page 150)
*
sample 1 240
* Read the datafile and name the variables -
read (data_6.1.shd) y x
* OLS regression without an intercept - y on x
ols y x / noconstant rstat
* Testing that the estimate of the coefficient on x is greater than 1
* by constructing a t-test:
test x=1
* OLS regression with an intercept - y on x
ols y x / rstat
stop