help: resetxt dialog:

Title

resetxt: Panel Data REgression Specification Error Tests (RESET)

Table of Contents

Syntax

Description

Model

Options

Saved Results

References

*** Examples

Authors

Syntax

resetxt depvar indepvars [if] [in] [weight] , id(var) it(var)

[ model(xtbe|xtfe|xtfm|xtfrontier|xtgls|xtkmhet1|xtkmhet2|xtkmhomo|)

(xtmle|xtpa|xtparks|xtpcse|xtrc|xtre|xtregar|xtsa|xttobit)

corr(name) panels(name) rhotype(name) noconstant

coll cost ti tvd igls hetonly indep noskip tobit twostep ]

Description

resetxt computes Panel Data REgression Specification Error Tests (RESET)

* Ho: Panel Model is Specified - Ha: Panel Model is Misspecified
- Ramsey RESET2 Test: Y= X Yh2
- Ramsey RESET3 Test: Y= X Yh2 Yh3
- Ramsey RESET4 Test: Y= X Yh2 Yh3 Yh4
- DeBenedictis-Giles Specification ResetL Test
- DeBenedictis-Giles Specification ResetS Test
- White Functional Form Test

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).

Model

1- model(xtbe) [xtreg , be] Between-Effects Panel Regression
2- model(xtfe) [xtreg , fe] Fixed-Effects Panel Regression
3- model(xtpa) [xtreg , pa] Population Averaged-Effects Panel Regression

4- model(xtmle) [xtreg , mle] MLE Random-Effects Panel Regression
5- model(xtfm) [NEW] Fama-MacBeth Panel Regression
6- model(xtrc) [xtrc] Swamy Random Coefficients Panel Regression
7- model(xtre) [xtreg , re] GLS Random-Effects Panel Regression

8- model(xtgls) [xtgls] Autocorrelation & Heteroskedasticity GLS Panel Regression
9- model(xtkmhomo) [xtgls] Kmenta Homoscedastic GLS AR(1) Panel Regression
* with Options: panels(iid) corr(psar1)
10- model(xtkmhet1) [xtgls] Kmenta Heteroscedastic GLS - different AR(1) in each Panel
* with Options: panels(het) corr(psar1)
11- model(xtkmhet2) [xtgls] Kmenta Heteroscedastic GLS - SAME/Common AR(1) in all Panels
* with Options: panels(het) corr(ar1)
12- model(xtparks) [xtgls] Parks Full Heteroscedastic Cross-Section GLS AR(1) Panel Regression
* with Options: panels(corr) corr(psar1)

13- model(xtpcse) [xtpcse] Corrected Standard Error Panel Regression
14- model(xtregar) [xtregar] AR(1) Panel Regression

15- model(xtfrontier) [xtfrontier] Stochastic Frontier Panel Regression

16- model(xttobit) [xttobit] Tobit Random-Effects Panel Regression

Options

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

be Between Effects (BE) model(xtbe)
fe Fixed-Effects (FE) model(xtfe, xtregar)
re GLS-Random-Effects (RE) model(xtre)
mle MLE-Random-Effects (MLE) model(xtmle)
pa Population-Averaged (PA) model(xtpa)

coll keep collinear variables; default is removing collinear variables.

cost Fit Cost Frontier instead of Production Function model(xtfrontier)

ti use Time-Invariant model(xtfrontier)

tvd use Time-Varying Decay model(xtfrontier)

noconstant Exclude Constant Term from Equation

hetonly assume panel-level heteroskedastic errors model(xtpcse)

igls iterated GLS instead of two-step GLS model(xtgls)

indep assume independent errors across panels model(xtpcse)

noskip likelihood-ratio test model(xttobit)

tobit likelihood-ratio test comparing against pooled tobit model(xttobit)

ll(#) value of minimum left-censoring dependent variable
with model(xttobit). Default is 0

twostep two-step estimate model(xtregar)

panels:(iid) Homoscedastic Error with No Cross-Sections Correlation
model(xtgls, xtpcse, xtregar)

panels:(het) Heteroscedastic Error with No Cross-Sections Correlation
model(xtgls, xtpcse, xtregar)

panels:(corr) Heteroscedastic Error with Cross-Sections Correlation
model(xtgls, xtpcse, xtregar)

corr:(indep) No Autocorrelation within Panels
model(xtgls, xtpcse, xtregar)

corr:(ar1) Common AR(1) Autocorrelation within Panels
model(xtgls, xtpcse, xtregar)

corr:(psar1) AR(1) Autocorrelation within Panels, and in each Panel
model(xtgls, xtpcse, xtregar)

corr:(corr) Autocorrelation within Panels
model(xtgls, xtpcse, xtregar)

rhotype(rhomethod) types of Rho estimators model(xtpcse, xtregar):

rhotype(dw) Durbin-Watson: rho_dw = 1 - dw/2

rhotype(regress) rho_reg = B from residual regression e_t = B*e_(t-1)

rhotype(freg) rho_leads = B from residual regression e_t = B*e_(t+1)

rhotype(tscorr) time series autocorrelation: rho_tscorr = e'e_(t-1)/e'e

rhotype(theil) Theil = rho_tscorr * (N-k)/N

rhotype(nagar) rho_nagar = (rho_dw * N*N+k*k)/(N*N-k*k)

rhotype(onestep) rho_onestep = (n/m_c)*rho_tscorr, where n is obs. and m_c is number of consecutive pairs of residuals

Saved Results

resetxt saves the following results in e():

e(resetf1) Ramsey Specification ResetF1 Test
e(resetf1p) Ramsey Specification ResetF1 Test P-Value
e(resetf2) Ramsey Specification ResetF2 Test
e(resetf2p) Ramsey Specification ResetF2 Test P-Value
e(resetf3) Ramsey Specification ResetF3 Test
e(resetf3p) Ramsey Specification ResetF3 Test P-Value

e(resetl1) DeBenedictis-Giles Specification ResetL1 Test
e(resetl1p) DeBenedictis-Giles Specification ResetL1 Test P-Value
e(resetl2) DeBenedictis-Giles Specification ResetL2 Test
e(resetl2p) DeBenedictis-Giles Specification ResetL2 Test P-Value
e(resetl3) DeBenedictis-Giles Specification ResetL3 Test
e(resetl3p) DeBenedictis-Giles Specification ResetL3 Test P-Value

e(resets1) DeBenedictis-Giles Specification ResetS1 Test
e(resets1p) DeBenedictis-Giles Specification ResetS1 Test P-Value
e(resets2) DeBenedictis-Giles Specification ResetS2 Test
e(resets2p) DeBenedictis-Giles Specification ResetS2 Test P-Value
e(resets3) DeBenedictis-Giles Specification ResetS3 Test
e(resets3p) DeBenedictis-Giles Specification ResetS3 Test P-Value

e(lmw) Functional Form White LM Test
e(lmwp) Functional Form White LM Test P-Value

References

Damodar Gujarati (1995)
"Basic Econometrics"
3rd Edition, McGraw Hill, New York, USA.

DeBenedictis, L. F. & Giles D. E. A. (1998)
"Diagnostic Testing in Econometrics: Variable Addition, RESET and Fourier Approximations",
In: A. Ullah & D. E. A. Giles (Eds.), Handbook of Applied Economic Statistics. Marcel Dekker, New York; 383-417.

Fama, E. F., & J. D. MacBeth (1973)
"Risk, Return, and Equilibrium: Empirical Tests"
Journal of Political Economy, Vol. 81, Issue 3; 607-636.

Fuller, W.A. & G.E. Battese (1974)
"Estimation of Linear Models with Cross-Error Structure",
Journal of Econometrics, 2; 67–78.

Greene, William (1993)
"Econometric Analysis",
2nd ed., Macmillan Publishing Company Inc., New York, USA..

Greene, William (2007)
"Econometric Analysis",
6th ed., Macmillan Publishing Company Inc., New York, USA..

Judge, Georege, R. Carter Hill, William . E. Griffiths, Helmut Lutkepohl, & Tsoung-Chao Lee (1988)
"Introduction To The Theory And Practice Of Econometrics",
2nd ed., John Wiley & Sons, Inc., New York, USA.

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.

Kmenta, Jan (1986)
"Elements of Econometrics",
2nd ed., Macmillan Publishing Company, Inc., New York, USA; 618-625.

Parks, R. (1967)
"Efficient Estimation of a System of Regression Equations when Disturbances are Both Serially and Contemporaneously Correlated",
Journal of the American Statisical Association, 62; 500-509.

Ramsey, J. B. (1969)
"Tests for Specification Errors in Classical Linear Least-Squares Regression Analysis",
Journal of the Royal Statistical Society, Series B 31; 350-371.

Examples

clear all

sysuse resetxt.dta, clear

db resetxt

xtset id t

* Between-Effects Panel Regression:
* xtbe resetxt y x1 x2 , id(id) it(t) model(xtbe)

* Fama-MacBeth Model Panel Regression
* xtfm resetxt y x1 x2 , id(id) it(t) model(xtfm)

* Fixed-Effects Panel Regression:
* xtfe resetxt y x1 x2 , id(id) it(t) model(xtfe)

* Population-Averaged Effects Panel Regression
* xtpa resetxt y x1 x2 , id(id) it(t) model(xtpa)

* Random-Effects MLE Panel Regression
* xtmle resetxt y x1 x2 , id(id) it(t) model(xtmle)

* Swamy Random-Coefficients Panel Regression
* xtrc resetxt y x1 x2 , id(id) it(t) model(xtrc)

* Random-Effects GLS Panel Regression
* xtre resetxt y x1 x2 , id(id) it(t) model(xtre)

* Autocorrelation & Heteroskedasticity Generalized Least Squares Panel Regression
* xtgls resetxt y x1 x2 , id(id) it(t) model(xtgls)

* Kmenta Homoscedastic Generalized Least Squares AR(1) Panel Regression
* xtkmhomo resetxt y x1 x2 , id(id) it(t) model(xtkmhomo)

* Kmenta Heteroscedastic GLS AR(1) different in each Panel
* xtkmhet1 resetxt y x1 x2 , id(id) it(t) model(xtkmhet1)

* Kmenta Heteroscedastic GLS AR(1) SAME/Common in all Panels
* xtkmhet2 resetxt y x1 x2 , id(id) it(t) model(xtkmhet2)

* Parks (FULL) Heteroscedastic Cross-Section GLS AR(1) Panel Regression
* xtparks resetxt y x1 x2 , id(id) it(t) model(xtparks)

* Linear Corrected Standard Error (PCSE) Panel Regression
* xtpcse resetxt y x1 x2 , id(id) it(t) model(xtpcse)

* Linear AR(1) Panel Regression
* xtregar resetxt y x1 x2 , id(id) it(t) model(xtregar)

* Frontier Panel Regression
* xtfrontier resetxt y x1 x2 , id(id) it(t) model(xtfrontier) ti
* xtfrontier resetxt y x1 x2 , id(id) it(t) model(xtfrontier) tvd
* xtfrontier resetxt y x1 x2 , id(id) it(t) model(xtfrontier) ti cost

* Tobit Panel Regression
* xttobit resetxt y x1 x2 , id(id) it(t) model(xttobit)

. clear all
. sysuse resetxt.dta, clear
. resetxt y x1 x2 , id(id) it(t) model(xtmle)

==============================================================================
* MLE Random-Effects Panel Data Regression
==============================================================================
y = x1 + x2
------------------------------------------------------------------------------
Sample Size = 49 | Cross Sections Number = 7
Wald Test = 56.6673 | P-Value > Chi2(2) = 0.0000
F-Test = 28.3337 | P-Value > F(2 , 40) = 0.0000
R2 (R-Squared) = 0.5345 | Raw Moments R2 = 0.9154
R2a (Adjusted R2) = 0.4414 | Raw Moments R2 Adj = 0.8984
Root MSE (Sigma) = 12.5053 | Log Likelihood Function = -180.4529
------------------------------------------------------------------------------
- R2h= 0.5500 R2h Adj= 0.4599 F-Test = 28.11 P-Value > F(2 , 40) 0.0000
- R2v= 0.3811 R2v Adj= 0.2573 F-Test = 14.16 P-Value > F(2 , 40) 0.0000
------------------------------------------------------------------------------
y | Coef. Std. Err. t P>|t| [95% Conf. Interval]
-------------+----------------------------------------------------------------
y |
x1 | -.267284 .0802264 -3.33 0.002 -.4294276 -.1051405
x2 | -1.216145 .2792884 -4.35 0.000 -1.780608 -.6516825
_cons | 62.88424 4.842509 12.99 0.000 53.09716 72.67131
------------------------------------------------------------------------------

==============================================================================
*** REgression Specification Error Tests (RESET) - Model= (xtmle)
==============================================================================
Ho: Model is Specified - Ha: Model is Misspecified
------------------------------------------------------------------------------
* Ramsey Specification ResetF Test
- Ramsey RESETF1 Test: Y= X Yh2 = 4.001 P-Value > F(1, 45) 0.0515
- Ramsey RESETF2 Test: Y= X Yh2 Yh3 = 1.994 P-Value > F(2, 44) 0.1483
- Ramsey RESETF3 Test: Y= X Yh2 Yh3 Yh4 = 2.403 P-Value > F(3, 43) 0.0806
------------------------------------------------------------------------------
* DeBenedictis-Giles Specification ResetL Test
- Debenedictis-Giles ResetL1 Test = 1.908 P-Value > F(2, 44) 0.1605
- Debenedictis-Giles ResetL2 Test = 1.391 P-Value > F(4, 42) 0.2535
- Debenedictis-Giles ResetL3 Test = 1.449 P-Value > F(6, 40) 0.2205
------------------------------------------------------------------------------
* DeBenedictis-Giles Specification ResetS Test
- Debenedictis-Giles ResetS1 Test = 0.236 P-Value > F(2, 44) 0.7910
- Debenedictis-Giles ResetS2 Test = 2.083 P-Value > F(4, 42) 0.1001
- Debenedictis-Giles ResetS3 Test = 2.192 P-Value > F(6, 40) 0.0639
------------------------------------------------------------------------------
- White Functional Form Test: E2= X X2 = 6.621 P-Value > Chi2(1) 0.0365
------------------------------------------------------------------------------

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

RESETXT Citation

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

RESETXT: "Stata Module to Compute Panel Data REgression Specification Error Tests (RESET)"

Online Help:

Official: xtdpd, xtfrontier, xtgls, xtivreg, xtpcse, xtrc, xtreg, xtregar, xttobit.

---------------------------------------------------------------------------

Panel Data Regression Models:
regxt Panel Data Econometric Regression Models: Stata Module Toolkit
xtregdhp Han-Philips (2010) Linear Dynamic Panel Data Regression
xtregam Amemiya Random-Effects Panel Data: Ridge & Weighted Regression
xtregbem Between-Effects Panel Data: Ridge & Weighted Regression
xtregbn Balestra-Nerlove Random-Effects Panel Data: Ridge & Weighted Regression
xtregfem Fixed-Effects Panel Data: Ridge & Weighted Regression
xtregmle Trevor Breusch MLE Random-Effects Panel Data: Ridge & Weighted Regression
xtregrem Fuller-Battese GLS Random-Effects Panel Data: Ridge & Weighted Regression
xtregsam Swamy-Arora Random-Effects Panel Data: Ridge & Weighted Regression
xtregwem Within-Effects Panel Data: Ridge & Weighted Regression
xtregwhm Wallace-Hussain Random-Effects Panel Data: Ridge & Weighted Regression
xtreghet MLE Random-Effects Multiplicative Heteroscedasticity Panel Data Regression
---------------------------------------------------------------------------

* Model Selection Diagnostic Criteria:
diagmle MLE Model Selection Diagnostic Criteria
diagnl NLS Model Selection Diagnostic Criteria
diagnlsur (NL-SUR) Overall System ModeL Selection Diagnostic Criteria
diagreg OLS Model Selection Diagnostic Criteria
diagreg2 2SLS-IV Model Selection Diagnostic Criteria
diagreg3 (3SLS-SUR) Overall System ModeL Selection Diagnostic Criteria
diagsem (SEM-FIML) Overall System ModeL Selection Diagnostic Criteria
diagvar (VAR) Overall System ModeL Selection Diagnostic Criteria
diagxt Panel Data ModeL Selection Diagnostic Criteria
---------------------------------------------------------------------------
* Linear vs Log-Linear Functional Form Tests:
lmfmle MLE Linear vs Log-Linear Functional Form Tests
lmfreg OLS Linear vs Log-Linear Functional Form Tests
lmfreg2 2SLS-IV Linear vs Log-Linear Functional Form Tests
---------------------------------------------------------------------------
lmhaus2 2SLS-IV Hausman Specification Test
lmhausxt Panel Data Hausman Specification Test
---------------------------------------------------------------------------
lmiden2 2SLS-IV Over Identification Restrictions Tests
---------------------------------------------------------------------------
lmeg Augmented Engle-Granger Cointegration Test
lmgc 2SLS-IV Granger Causality Test
lmsrd OLS Spurious Regression Diagnostic
---------------------------------------------------------------------------
* REgression Specification Error Tests (RESET):
reset OLS REgression Specification Error Tests (RESET)
reset2 2SLS-IV REgression Specification Error Tests (RESET)
resetmle MLE REgression Specification Error Tests (RESET)
resetxt Panel Data REgression Specification Error Tests (RESET)
---------------------------------------------------------------------------