help: lmhcwxt dialog:

Title

lmhcwxt: Panel Data Heteroscedasticity Cook-Weisberg Test

Table of Contents

Syntax

Options

Description

Saved Results

References

*** Examples

Authors

Syntax

lmhcwxt depvar indepvars [if] [in] , id(var) it(var) [ noconstant cross coll ]

Options

* id(var) Cross Sections ID variable name
* it(var) Time Series ID variable name

cross estimates each Cross Section regression,
to stack each residual variable in one variable,
and the same method for predict variable.

coll keep collinear variables; default is removing collinear variables.

noconstant Exclude Constant Term from Equation

Description

lmhcwxt computes Panel Data Heteroscedasticity Cook-Weisberg Test.

* Ho: Panel Homoscedasticity - Ha: Panel Heteroscedasticity
- Cook-Weisberg LM Test E = Yh
- Cook-Weisberg LM Test E = X

*** Single Variable Tests
- Cook-Weisberg LM Test: E = xi
- King LM Test: E = xi

R2, R2 Adjusted, and F-Test, are obtained from 4 ways:

1- (Buse 1973) R2.

2- Raw Moments R2.

3- squared correlation between predicted (Yh) and observed dependent variable (Y).

4- Ratio of variance between predicted (Yh) and observed dependent variable (Y).

- Adjusted R2: R2_a=1-(1-R2)*(N-1)/(N-K-1).

- F-Test=R2/(1-R2)*(N-K-1)/(K).

Saved Results

lmhcwxt saves the following results in e():

e(lmhcw1) Cook-Weisberg LM Test E2/Sig2n = Yh
e(lmhcw1p) Cook-Weisberg LM Test E2/Sig2n = Yh P-Value
e(lmhcw2) Cook-Weisberg LM Test E2/Sig2n = X
e(lmhcw2p) Cook-Weisberg LM Test E2/Sig2n = X P-Value
e(lmhcw_xi) Cook-Weisberg LM Single Variable Test
e(lmhcwp_xi) Cook-Weisberg LM Single Variable Test P-Value
e(lmhq_xi) King LM Single Variable Test
e(lmhqp_xi) King LM Single Variable Test P-Value

References

Cook, R.D., & S. Weisberg (1983)
"Diagnostics for Heteroscedasticity in Regression",
Biometrica 70; 1-10.

Judge, Georege, W. E. Griffiths, R. Carter Hill, Helmut Lutkepohl, & Tsoung-Chao Lee(1985)
"The Theory and Practice of Econometrics",
2nd ed., John Wiley & Sons, Inc., New York, USA.

Szroeter, J. (1978)
"A Class of Parametric Tests for Heteroscedasticity in Linear Econometric Models",
Econometrica, 46; 1311-28.

Examples

clear all

sysuse lmhcwxt.dta, clear

db lmhcwxt

lmhcwxt y x1 x2 , id(id) it(t)

. clear all
. sysuse lmhcwxt.dta, clear
. lmhcwxt y x1 x2 , id(id) it(t)

==============================================================================
* Ordinary Least Squares (OLS) Regression
==============================================================================
y = x1 + x2
------------------------------------------------------------------------------
Sample Size = 49 | Cross Sections Number = 7
Wald Test = 56.7713 | P-Value > Chi2(2) = 0.0000
F-Test = 28.3857 | P-Value > F(2 , 46) = 0.0000
R2 (R-Squared) = 0.5524 | Raw Moments R2 = 0.9186
R2a (Adjusted R2) = 0.5329 | Raw Moments R2 Adj = 0.9151
Root MSE (Sigma) = 11.4350 | Log Likelihood Function = -187.3772
------------------------------------------------------------------------------
- R2h= 0.5524 R2h Adj= 0.5329 F-Test = 28.39 P-Value > F(2 , 46) 0.0000
- R2v= 0.5524 R2v Adj= 0.5329 F-Test = 28.39 P-Value > F(2 , 46) 0.0000
------------------------------------------------------------------------------
y | Coef. Std. Err. t P>|t| [95% Conf. Interval]
-------------+----------------------------------------------------------------
x1 | -.2739317 .1031986 -2.65 0.011 -.4816598 -.0662037
x2 | -1.597311 .3341306 -4.78 0.000 -2.269881 -.9247407
_cons | 68.61898 4.735484 14.49 0.000 59.08694 78.15101
------------------------------------------------------------------------------

==============================================================================
*** Panel Data Heteroscedasticity Cook-Weisberg Test
==============================================================================
Ho: Panel Homoscedasticity - Ha: Panel Heteroscedasticity

- Cook-Weisberg LM Test: E2/S2n = Yh = 0.9872 P-Value > Chi2(1) 0.3204
- Cook-Weisberg LM Test: E2/S2n = X = 10.0129 P-Value > Chi2(2) 0.0067
------------------------------------------------------------------------------
*** Single Variable Tests (E2/Sig2):
- Cook-Weisberg LM Test: x1 = 1.2953 P-Value > Chi2(1) 0.2551
- Cook-Weisberg LM Test: x2 = 3.9532 P-Value > Chi2(1) 0.0468
------------------------------------------------------------------------------
*** Single Variable Tests:
- King LM Test: x1 = 0.2187 P-Value > Chi2(1) 0.6400
- King LM Test: x2 = 4.2370 P-Value > Chi2(1) 0.0396
------------------------------------------------------------------------------

Authors

- Emad Abd Elmessih Shehata
Professor (PhD Economics)
Agricultural Research Center - Agricultural Economics Research Institute - Egypt
Email: emadstat@hotmail.com
WebPage: http://emadstat.110mb.com/stata.htm
WebPage at IDEAS: http://ideas.repec.org/f/psh494.html
WebPage at EconPapers: http://econpapers.repec.org/RAS/psh494.htm

- Sahra Khaleel A. Mickaiel
Professor (PhD Economics)
Cairo University - Faculty of Agriculture - Department of Economics - Egypt
Email: sahra_atta@hotmail.com
WebPage: http://sahraecon.110mb.com/stata.htm
WebPage at IDEAS: http://ideas.repec.org/f/pmi520.html
WebPage at EconPapers: http://econpapers.repec.org/RAS/pmi520.htm

LMHCWXT Citation

Shehata, Emad Abd Elmessih & Sahra Khaleel A. Mickaiel (2015)

LMHCWXT: "Stata Module to Compute Panel Data Heteroscedasticity Cook-Weisberg Test"

Online Help:

* Heteroscedasticity Tests:

* (1) (OLS) * Ordinary Least Squares Tests:
lmhreg OLS Heteroscedasticity Tests
lmharch OLS Heteroscedasticity Engle (ARCH) Test
lmhcw OLS Heteroscedasticity Cook-Weisberg Test
lmhgl OLS Heteroscedasticity Glejser Test
lmhharv OLS Heteroscedasticity Harvey Test
lmhhp OLS Heteroscedasticity Hall-Pagan Test
lmhmss OLS Heteroscedasticity Machado-Santos-Silva Test
lmhwald OLS Heteroscedasticity Wald Test
lmhwhite OLS Heteroscedasticity White Test
---------------------------------------------------------------------------
* (2) (NLS) * Non Linear Least Squares Tests:
lmhnls Non Linear Least Squares Heteroscedasticity Tests
lmharchnl NLS Heteroscedasticity Engle (ARCH) Test
lmhcwnl NLS Heteroscedasticity Cook-Weisberg Test
lmhglnl NLS Heteroscedasticity Glejser Test
lmhharvnl NLS Heteroscedasticity Harvey Test
lmhhpnl NLS Heteroscedasticity Hall-Pagan Test
lmhmssnl NLS Heteroscedasticity Machado-Santos-Silva Test
lmhwaldnl NLS Heteroscedasticity Wald Test
lmhwhitenl NLS Heteroscedasticity White Test
---------------------------------------------------------------------------
* (3) (MLE) * Maximum Likelihood Estimation Tests:
lmhmle MLE Heteroscedasticity Tests
lmharchml MLE Heteroscedasticity Engle (ARCH) Test
lmhcwml MLE Heteroscedasticity Cook-Weisberg Test
lmhglml MLE Heteroscedasticity Glejser Test
lmhharvml MLE Heteroscedasticity Harvey Test
lmhhpml MLE Heteroscedasticity Hall-Pagan Test
lmhmssml MLE Heteroscedasticity Machado-Santos-Silva Test
lmhwaldml MLE Heteroscedasticity Wald Test
lmhwhiteml MLE Heteroscedasticity White Test
---------------------------------------------------------------------------
* (4) (2SLS-IV) * Two-Stage Least Squares & Instrumental Variables Tests:
lmhreg2 2SLS-IV Heteroscedasticity Tests
lmharch2 2SLS-IV Heteroscedasticity Engle (ARCH) Test
lmhcw2 2SLS-IV Heteroscedasticity Cook-Weisberg Test
lmhgl2 2SLS-IV Heteroscedasticity Glejser Test
lmhharv2 2SLS-IV Heteroscedasticity Harvey Test
lmhhp2 2SLS-IV Heteroscedasticity Hall-Pagan Test
lmhmss2 2SLS-IV Heteroscedasticity Machado-Santos-Silva Test
lmhwald2 2SLS-IV Heteroscedasticity Wald Test
lmhwhite2 2SLS-IV Heteroscedasticity White Test
---------------------------------------------------------------------------
* (5) Panel Data Tests:
lmhxt Panel Data Heteroscedasticity Tests
lmhgwxt Panel Data Groupwise Heteroscedasticity Tests
ghxt Panel Groupwise Heteroscedasticity Tests
lmhlmxt Panel Data Groupwise Heteroscedasticity Breusch-Pagan LM Test
lmhlrxt Panel Data Groupwise Heteroscedasticity Greene LR Test
lmharchxt Panel Data Heteroscedasticity Engle (ARCH) Test
lmhcwxt Panel Data Heteroscedasticity Cook-Weisberg Test
lmhglxt Panel Data Heteroscedasticity Glejser Test
lmhharvxt Panel Data Heteroscedasticity Harvey Test
lmhhpxt Panel Data Heteroscedasticity Hall-Pagan Test
lmhmssxt Panel Data Heteroscedasticity Machado-Santos-Silva Test
lmhwaldxt Panel Data Heteroscedasticity Wald Test
lmhwhitext Panel Data Heteroscedasticity White Test
---------------------------------------------------------------------------
* (6) (3SLS-SUR) * Simultaneous Equations Tests:
lmareg3 (3SLS-SUR) Overall System Autocorrelation Tests
lmhreg3 (3SLS-SUR) Overall System Heteroscedasticity Tests
lmnreg3 (3SLS-SUR) Overall System Non Normality Tests
lmcovreg3 (3SLS-SUR) Breusch-Pagan Diagonal Covariance Matrix
r2reg3 (3SLS-SUR) Overall System R2, F-Test, and Chi2-Test
diagreg3 (3SLS-SUR) Overall System ModeL Selection Diagnostic Criteria
---------------------------------------------------------------------------
* (7) (SEM-FIML) * Structural Equation Modeling Tests:
lmasem (SEM-FIML) Overall System Autocorrelation Tests
lmhsem (SEM-FIML) Overall System Heteroscedasticity Tests
lmnsem (SEM-FIML) Overall System Non Normality Tests
lmcovsem (SEM-FIML) Breusch-Pagan Diagonal Covariance Matrix Test
r2sem (SEM-FIML) Overall System R2, F-Test, and Chi2-Test
diagsem (SEM-FIML) Overall System ModeL Selection Diagnostic Criteria
---------------------------------------------------------------------------
* (8) (NL-SUR) * Non Linear Seemingly Unrelated Regression Tests:
lmanlsur (NL-SUR) Overall System Autocorrelation Tests
lmhnlsur (NL-SUR) Overall System Heteroscedasticity Tests
lmnnlsur (NL-SUR) Overall System Non Normality Tests
lmcovnlsur (NL-SUR) Breusch-Pagan Diagonal Covariance Matrix Test
r2nlsur (NL-SUR) Overall System R2, F-Test, and Chi2-Test
diagnlsur (NL-SUR) Overall System ModeL Selection Diagnostic Criteria
---------------------------------------------------------------------------
* (9) (VAR) * Vector Autoregressive Model Tests:
lmavar (VAR) Overall System Autocorrelation Tests
lmhvar (VAR) Overall System Heteroscedasticity Tests
lmnvar (VAR) Overall System Non Normality Tests
lmcovvar (VAR) Breusch-Pagan Diagonal Covariance Matrix Test
r2var (VAR) Overall System R2, F-Test, and Chi2-Test
diagvar (VAR) Overall System ModeL Selection Diagnostic Criteria
---------------------------------------------------------------------------