BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
MattvanPallen
Calcite | Level 5

Hi Again!

Hope this is the last time I'm forced to bother you, as the sas help doc is for me

I wanted to test for heteroscedasticity in my panel data sample and eventually correct it.

My model:

FE=FELO FEUP FE_L FELOWER FEUPER;

FELO - dummy (1 if below FE_L Q1)

FEUP - dummy (1 if above FE_L Q1)

FE_L - laged FE

FELOWER = FELO*FE_L

FEUPER =FEUP*FE_L

On SAS Help I can only find the example with "incomes" which is not as complicated as my...

I would really appreciate your time and concern.

1 ACCEPTED SOLUTION

Accepted Solutions
ets_kps
SAS Employee

Hello and thanks for the question. 

There are two parts to your question.  If you want to conduct a Breusch-Pagan test which is requested as an option on the MODEL statement in PROC PANEL. 

SAS/ETS(R) 13.1 User's Guide

The second, and frankly what I would do, is to just assume you have heteroskedasticity and autocorrelation and correct for it using the HAC=NEWEYWEST option on the MODEL statement.SAS/ETS(R) 13.1 User's Guide

If you wanted to employ simply Heteroskedastic-corrected se's you can do that here.

SAS/ETS(R) 13.1 User's Guide

Good luck and let us know if you need anything else. -Ken

View solution in original post

4 REPLIES 4
ets_kps
SAS Employee

Hello and thanks for the question. 

There are two parts to your question.  If you want to conduct a Breusch-Pagan test which is requested as an option on the MODEL statement in PROC PANEL. 

SAS/ETS(R) 13.1 User's Guide

The second, and frankly what I would do, is to just assume you have heteroskedasticity and autocorrelation and correct for it using the HAC=NEWEYWEST option on the MODEL statement.SAS/ETS(R) 13.1 User's Guide

If you wanted to employ simply Heteroskedastic-corrected se's you can do that here.

SAS/ETS(R) 13.1 User's Guide

Good luck and let us know if you need anything else. -Ken

rohitg
Calcite | Level 5

Hi,

I was trying to follow your steps using SAS 9.4, but it is not working: I need to test if there is any hetroscedasticity and also how I can correct it.

 

proc panel data=mydata;

model y=x1 x2 x3 x4/RANTWO HAC=NEWEYWEST;

id firm time;run;

 

Please help!

..Rohit

SteveDenham
Jade | Level 19

In 9.4 (SAS/ETS 14.1), the specification is now:

 

HAC(neweywest94)

 

or

 

NEWEYWEST (parameters inserted for gamma, rate and constant, if you want something other than the default)

 

Hope this helps.

 

Steve Denham

 

 

rohitg
Calcite | Level 5

Hey, Thanks for your reply! I have access to 9.4 (SAS/ETS 13.2).

 

To correct  heteroscedasticity, I have succesfully tried and used:

 

proc panel data=mydata;

model y=x1 x2 x3 x4/RANTWO HAC(BANDWIDTH=NEWEYWEST94);

id firm time;run;

 

Could you please suggest some way through which I can check for hetroscedsaticty in my panel data before looking for any correction ?

Thanks.

Rohit

 

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

Multiple Linear Regression in SAS

Learn how to run multiple linear regression models with and without interactions, presented by SAS user Alex Chaplin.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 4 replies
  • 4608 views
  • 1 like
  • 4 in conversation