(This may not be the most clever question ever.)
I would like to create a two-way panel so I can use two sets of fixed effects. Think of one id being a student grade and the other being a department. The two together do not give a unique identifier, since a student may take multiple courses in one department.
When I restructure, I get a three dimensional panel to get a unique id. But then I don't get the option to use fixed effects.
What am I missing?
two way panel
Moderators: EViews Gareth, EViews Jason, EViews Steve, EViews Moderator
-
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13305
- Joined: Tue Sep 16, 2008 5:38 pm
Re: two way panel
We don't offer fixed effects for 3D panels. Only two dimensions (even if one of them isn't time).
Follow us on Twitter @IHSEViews
-
- Non-normality and collinearity are NOT problems!
- Posts: 3775
- Joined: Wed Sep 17, 2008 2:25 pm
Re: two way panel
EViews Gareth wrote:We don't offer fixed effects for 3D panels. Only two dimensions (even if one of them isn't time).
That's kind of what I thought. The issue is that sometimes one wants to do fixed effects and there's no way to do that without creating a panel.
-
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13305
- Joined: Tue Sep 16, 2008 5:38 pm
-
- Non-normality and collinearity are NOT problems!
- Posts: 3775
- Joined: Wed Sep 17, 2008 2:25 pm
Re: two way panel
One dimension has about 100 categories. That'll work. The other has 20,000. I need something to sweep out the dummies.
-
- EViews Developer
- Posts: 2671
- Joined: Wed Oct 15, 2008 9:17 am
Re: two way panel
If you have three variables, say Y, X1, and X2, you can easily demean using
where ID is the categorization variable corresponding to the 10,000 dummies. The result will be the series with means-by-category removed.
Code: Select all
frml ydm = y - @meansby(y, id)
frml x1dm = x - @meansby(x1, id)
frml x2dm = x - @meansby(x2, id)
where ID is the categorization variable corresponding to the 10,000 dummies. The result will be the series with means-by-category removed.
-
- Non-normality and collinearity are NOT problems!
- Posts: 3775
- Joined: Wed Sep 17, 2008 2:25 pm
Re: two way panel
EViews Glenn wrote:If you have three variables, say Y, X1, and X2, you can easily demean usingCode: Select all
frml ydm = y - @meansby(y, id)
frml x1dm = x - @meansby(x1, id)
frml x2dm = x - @meansby(x2, id)
where ID is the categorization variable corresponding to the 10,000 dummies. The result will be the series with means-by-category removed.
Yes, but one of the other variables is an @expand with about 50 categories. So 50 dummies would have to be generated and demeaned. Is there an easy way to do that?
-
- EViews Developer
- Posts: 2671
- Joined: Wed Oct 15, 2008 9:17 am
Re: two way panel
The @expand should work for the remaining dimension, no?
-
- Non-normality and collinearity are NOT problems!
- Posts: 3775
- Joined: Wed Sep 17, 2008 2:25 pm
Re: two way panel
The @expand dummies would need to be treated by the @meansby demeaning, no?
-
- EViews Developer
- Posts: 2671
- Joined: Wed Oct 15, 2008 9:17 am
Re: two way panel
True. I forget that you are unbalanced.
Who is online
Users browsing this forum: No registered users and 18 guests