* Heteroskedasticity in OLS Model for Compensation * * Keywords: * regression, ols, linear, heteroskedasticity, park, test, compensation * * Description: * We illustrate how to estimate a linear OLS Model for Compensation * and use Park's Heteroskedasticity Test * * Author(s): * Skif Pankov * * Source: * Damodar N. Gujarati and Dawn C. Porter, Basic Econometrics - 5th Edition * McGraw-Hill International Edition, Chapter 11, Example 11.1 (page 379) * sample 1 9 * Reading the datafile and naming variables read(data_11.1.shd) comp prod * Running an OLS regression of comp on prod, stating to include residual * statistics and to save residuals in a variable reds ols comp prod / rstat resid = reds * Requiring to test the previous regression for heteroskedasticity diagnos / het * Generating variables genr lnu2 = log(reds**2) genr lnprod = log(prod) * Running an OLS regression of newly generated lnu2 on lnprod, stating to include *residual statistics ols lnu2 lnprod / rstat stop