Running redundant variable test with panel data

For technical questions regarding estimation of single equations, systems, VARs, Factor analysis and State Space Models in EViews. General econometric questions and advice should go in the Econometric Discussions forum.

Moderators: EViews Gareth, EViews Moderator

kian
Posts: 15
Joined: Tue Jan 13, 2009 7:45 am

Running redundant variable test with panel data

Postby kian » Thu Mar 05, 2009 5:00 am

Hi there,
I'm running a panel dataset which is unbalanced. When I try to test for redundant variables in Eviews I get this caption come up:-
"the test specifications have different samples due to NAs in original or test series. Re-estimate original equation with restricted sample and rerun test."
What does this mean?
How can I get around this so that I can carry out redundant variable tests?!
Please please help, I'm really in a pickle with this!
Thanks!

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13600
Joined: Tue Sep 16, 2008 5:38 pm

Re: Running redundant variable test with panel data

Postby EViews Gareth » Thu Mar 05, 2009 10:22 am

This error message is somewhat self explanatory...

The redundant variables test is performed by comparing the original regression with a secondary regression, which is exactly the same apart from the fact that the test variables are dropped.

An important requirement of any sort of test that involves running a secondary regression is that the sample (i.e. the observations) used in both tests must be identical.

The way that EViews does these tests is that it takes the original regression specification, drops the test variables, and then estimates a second regression. That second regression has exactly the same specification and options as the first regression (other than the dropped variables).

Note that EViews also automatically drops an observation from an equation if that observation has an NA value for any of the variables in the equation. This feature can cause problems with secondary regression tests because it can cause the sample used in the secondary regression to be different. For example, say your original equation is:

Y C X1 X2 X3

over the sample 1990 2010

and X2 contains NAs for the year 1995 and 1996. The original equation would drop those two years from the estimation.

Suppose you then do a redundant variable test, and choose X2 as the test variable. The secondary equation is then:

Y C X1 X3

over the sample 1990 2010.

Now however there are no NAs in the equation, so the years 1995 and 1996 are no longer dropped. Thus the samples for the two equations are no longer the same, hence the error message.


As the error message points out, you can fix this, by explicitly saying in the original equation that you don't want those two years. Thus, if in the first equation you had set the sample to be

1990 2010 if X2<>NA (i.e. over the years 1990 to 2010, but only for observations where X2 is not NA)

Then that sample would be passed onto the secondary equation too, and they would both have the same sample.

startz
Non-normality and collinearity are NOT problems!
Posts: 3797
Joined: Wed Sep 17, 2008 2:25 pm

Re: Running redundant variable test with panel data

Postby startz » Thu Mar 05, 2009 11:40 am

This error message is somewhat self explanatory...

The redundant variables test is performed by comparing the original regression with a secondary regression, which is exactly the same apart from the fact that the test variables are dropped.

An important requirement of any sort of test that involves running a secondary regression is that the sample (i.e. the observations) used in both tests must be identical.

The way that EViews does these tests is that it takes the original regression specification, drops the test variables, and then estimates a second regression. That second regression has exactly the same specification and options as the first regression (other than the dropped variables).

>snip.
Perhaps EViews could be made smart enough to re-use the original sample?

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13600
Joined: Tue Sep 16, 2008 5:38 pm

Re: Running redundant variable test with panel data

Postby EViews Gareth » Thu Mar 05, 2009 12:30 pm

For non-panels, that's exactly what it does - but in panels things are a little bit more complicated.

startz
Non-normality and collinearity are NOT problems!
Posts: 3797
Joined: Wed Sep 17, 2008 2:25 pm

Re: Running redundant variable test with panel data

Postby startz » Thu Mar 05, 2009 12:45 pm

For non-panels, that's exactly what it does - but in panels things are a little bit more complicated.
All the more reason EViews should do it?
And, thinking of home and looking northwest, do you happen to know of company that will rent a car in Ireland to someone who is 22?

kian
Posts: 15
Joined: Tue Jan 13, 2009 7:45 am

Re: Running redundant variable test with panel data

Postby kian » Thu Mar 05, 2009 1:20 pm

Thanks for the help guys, I'll see if I can get around this by using your method Gareth...
Cheeky I know, but are there any other software packages that will do this automatically for me? In particular will Stata do this for me?
Thanks again!

kian
Posts: 15
Joined: Tue Jan 13, 2009 7:45 am

Re: Running redundant variable test with panel data

Postby kian » Thu Mar 05, 2009 1:36 pm

Ok so say I want to conduct a range of redundant variable tests on a range of different combinations of variables, should I then explicitly state in the original estimation that I want only observations where each variable is not equal to NA.

Can I impose more than one "if" condition on my sample? How??

Also, I'm assuming this will not affect the initial amount of observations in the initial regression, right?

Cheers guys!

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13600
Joined: Tue Sep 16, 2008 5:38 pm

Re: Running redundant variable test with panel data

Postby EViews Gareth » Thu Mar 05, 2009 2:14 pm

It shouldn't change the number of observations in the original equation.

You can string further if conditions together with an AND:

smpl 1990 2010 if x<>na and y<>na and z<>na

kian
Posts: 15
Joined: Tue Jan 13, 2009 7:45 am

Re: Running redundant variable test with panel data

Postby kian » Thu Mar 05, 2009 3:04 pm

Excellent massive help, cheers guys!
One other quick question is there any difference (statistically) form running a wlad test where all coefficients are equal to zero and running a redundant variables test for all the variables?

startz
Non-normality and collinearity are NOT problems!
Posts: 3797
Joined: Wed Sep 17, 2008 2:25 pm

Re: Running redundant variable test with panel data

Postby startz » Thu Mar 05, 2009 3:15 pm

Excellent massive help, cheers guys!
One other quick question is there any difference (statistically) form running a wlad test where all coefficients are equal to zero and running a redundant variables test for all the variables?
if the model is linear, you should get identical results. If the model is nonlinear, the tests are asymptotically acquivalent but not identical.

EViews Glenn
EViews Developer
Posts: 2682
Joined: Wed Oct 15, 2008 9:17 am

Re: Running redundant variable test with panel data

Postby EViews Glenn » Fri Mar 06, 2009 10:48 am

I'm a little late to the party, but want to make one other comment on the sample exclusions. An easy way to string together a bunch of NA excludes is to put the variables you want to exclude in a group, say

Code: Select all

group todrop x y z
then set your sample to drop observations that have NAs anywhere in the row

Code: Select all

smpl if @rnas(todrop)=0


Return to “Estimation”

Who is online

Users browsing this forum: No registered users and 1 guest