<p><code>vif</code> calculates the variance inflation factors, a common metric of multicollinearity. Usually multicollinearity is not a big deal, unless it is perfect multicollinearity. This seems to be the case here. If year ranges from 1981 to 1987, then yes, you have to drop one of the year dummies. Otherwise you would end up in the <a href="https://www.statology.org/dummy-variable-trap/" rel="nofollow noreferrer">dummy variable trap</a>. I have no idea how Stata chooses which one to drop (anybody else?), but note that you can also specify which one to drop by typing something like <code>ib1981.state</code>. Then the year 1981 will then be the &quot;base category&quot; and the other coefficients be relative to this.</p>

CC BY-SA 4.0
2022-06-20T20:48:18.640Z
Hi, thanks for the reply. I should have been a little more specific in the data. The data is available from 1980-1987, so 1980 is automatically removed. Now the question is why 1987 is also removed. If you remove jobexp for example, then 1987 remains in the model. Does this mean that the variable "jobexp" and the year 1987 are perfectly correlated, i.e. that there is perfect multicollinearity? How can I observe this perfect multicollinearity in STATA?
Karl Seidl
CC BY-SA 4.0
2022-06-20T20:54:14.547Z
What exactly then correlates with jobexp? The whole year 1987? How do you argue/justify this multicollinearity?
Karl Seidl
CC BY-SA 4.0
2022-06-21T04:19:14.097Z
Welcome, @KarlSeidl You are observing perfect collinearity. Your results (some variables dropped) say so. Which variables cause it cannot be determined from the regression results. Careful (tedious) examination of the full data set is required. You could try regressing `educ` on `i.state`, on `jobexp`, and on `i.state` and `jobexp`, etc., `jobexp` on `educ`, on `i.state`, and on `educ` and `i.state`, etc., to have some ideas.
chan1142
CC BY-SA 4.0
2022-06-21T07:34:05.967Z
@chan1142 Thanks. I will try that. What exactly do i have to Look for while regressing, to determine which variable causes the perfect multicollinearity?
Karl Seidl
CC BY-SA 4.0
2022-06-21T07:36:15.987Z
Rsq = 1 means the lhs variable is perfectly explained by the rhs variables.
chan1142
CC BY-SA 4.0
2022-06-21T08:34:14.020Z
@chan1142 Thanks makes Sense. Is it possible to regress solely the year 1987 f.e. on educ? How would such Code Look Like?
Karl Seidl
CC BY-SA 4.0
2022-06-21T11:46:02.550Z
You can read the Stata manual for `varlist`. I would also try cross tables.
chan1142
CC BY-SA 4.0
2022-06-21T15:10:22.160Z
@chan1142 Thanks will give it a try. One Thing i find a bit irritating. Whenever i used a FE estimation, the year 1987 get removed when jobexp is included. But whenever i use an OLS estimation neither one get removed? Why could that be?
Karl Seidl
CC BY-SA 4.0
2022-06-20T17:02:23.170Z
2022-06-20T18:37:08.290Z
2022-06-20T18:37:08.290Z
Papayapap
<p>i recently ran a regression with fixed effects. As expected, STATA removed one of the dummy-variables, as well as every time-invariant variable (educ). My question is now. Why does STATA also removes the Dummy from 1987? Whenever i remove 'jobexp' from the model, 1987 is included again? My guess is a strong (perfect) multicolinearity. But how do i test for it? Any ideas?</p>
<p><a href="https://i.sstatic.net/X7vQA.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/X7vQA.png" alt="enter image description here" /></a></p>

<regression><paneldata>
Test for Multicolinearity
Karl Seidl
# Test for Multicolinearity

(Asked by: username_0 on 2022-06-20)

i recently ran a regression with fixed effects. As expected, STATA removed one of the dummy-variables, as well as every time-invariant variable (educ). My question is now. Why does STATA also removes the Dummy from 1987? Whenever i remove 'jobexp' from the model, 1987 is included again? My guess is a strong (perfect) multicolinearity. But how do i test for it? Any ideas?

[![enter image description here](https://i.sstatic.net/X7vQA.png)](https://i.sstatic.net/X7vQA.png)

**Tags:** regression, paneldata

---

## 1 answers

### Answer by username_1 on 2022-06-20. Score: 2

`vif` calculates the variance inflation factors, a common metric of multicollinearity. Usually multicollinearity is not a big deal, unless it is perfect multicollinearity. This seems to be the case here. If year ranges from 1981 to 1987, then yes, you have to drop one of the year dummies. Otherwise you would end up in the [dummy variable trap](https://www.statology.org/dummy-variable-trap/). I have no idea how Stata chooses which one to drop (anybody else?), but note that you can also specify which one to drop by typing something like `ib1981.state`. Then the year 1981 will then be the "base category" and the other coefficients be relative to this.

> **Comments:**
> **username_0**: Hi, thanks for the reply. I should have been a little more specific in the data. The data is available from 1980-1987, so 1980 is automatically removed. Now the question is why 1987 is also removed. If you remove jobexp for example, then 1987 remains in the model. Does this mean that the variable "jobexp" and the year 1987 are perfectly correlated, i.e. that there is perfect multicollinearity? How can I observe this perfect multicollinearity in STATA?  
> **username_0**: What exactly then correlates with jobexp? The whole year 1987? How do you argue/justify this multicollinearity?  
> **username_2**: Welcome, @KarlSeidl You are observing perfect collinearity. Your results (some variables dropped) say so. Which variables cause it cannot be determined from the regression results. Careful (tedious) examination of the full data set is required. You could try regressing `educ` on `i.state`, on `jobexp`, and on `i.state` and `jobexp`, etc., `jobexp` on `educ`, on `i.state`, and on `educ` and `i.state`, etc., to have some ideas.  
> **username_0**: @chan1142 Thanks. I will try that. What exactly do i have to Look for while regressing, to determine which variable causes the perfect multicollinearity?  
> **username_2**: Rsq = 1 means the lhs variable is perfectly explained by the rhs variables.  
> **username_0**: @chan1142 Thanks makes Sense. Is it possible to regress solely the year 1987 f.e. on educ? How would such Code Look Like?  
> **username_2**: You can read the Stata manual for `varlist`. I would also try cross tables.  
> **username_0**: @chan1142 Thanks will give it a try. One Thing i find a bit irritating. Whenever i used a FE estimation, the year 1987 get removed when jobexp is included. But whenever i use an OLS estimation neither one get removed? Why could that be?  

---

