3
$\begingroup$

I have a panel dataset with countries as individuals observed per year. My analysis concerns a macroeconomic study and as often happens in these cases (I would not be wrong but they are commonly called "macro-panel" or "wide-panel"). I have few temporal observations per country, about 15-24 years, and there is evidence of individual heterogeneity, i.e. with an individual unobserved effects.

Using static panel models, the literature suggests using fixed-effect models in such cases, but in the models I am analyzing the Hausman test tells me the opposite, preferring the random-effect models. I don't understand why I get this result. I'm starting to think that it is due to the presence of variables that change little or no at all over time, and this generates problems in fixed models. However, I consider these regressors important for my analysis and therefore I would like to know if it is coherent to choose the random effects and how I can justify this choice.

Also my models suffer from both cross-sectional dependence and serial correlation. I don't know how much of a problem this can be, the only way I'm dealing with them is by using robust standard errors. On the other hand, I have found research regarding my work and most of them are based on dynamic models, using generalized method of moments (GMM) with a lagged dependent variable as a regressor. Unfortunately, I don't know well the theory on which GMMs are based, but I have learned of their versatility, especially in situations like these, which has made them increasingly used in recent years.

Therefore, given the diagnostic problems I am having with static models, I wonder if it is more appropriate to use dynamic models, or to stay on fixed / random models taking the necessary precautions, and on the basis of what I can evaluate this choice, comparing the results obtained with the two different approaches (static vs dynamic).

I hope I was clear.

$\endgroup$
6
  • $\begingroup$ Perhaps working on your variables with PCA to construct a reduced dimension of meaningful constructs that are independent is a first step. $\endgroup$
    – AJKOER
    Sep 28, 2020 at 12:23
  • $\begingroup$ Do you wish to draw inferences about countries outside of your sample? Also, how many countries do you have? $\endgroup$ Sep 28, 2020 at 12:49
  • $\begingroup$ @AJKOER I could try, but I think the PCA can't help me in this case, given that the variables I use are already "independent" both at the correlation level (in order to avoid multicollinearity) and in informative terms to explain the model. To be more clear, my "typical" model usually has a regressor that represents an economic income component (use GDP per capita), another that captures the demographic effect of countries and so on. Also, based on previous works no one uses PCA, at most proceeds with a log or first-difference transformation (or log difference). $\endgroup$
    – UzbeKistaN
    Sep 28, 2020 at 14:17
  • $\begingroup$ @ThomasBilach Sorry but I think I don't understand what you mean. In a panel regression, the purpose should be to observe how the phenomenon has evolved both at a transversal and temporal level. So the answer to your first question is no. I am analyzing European countries and I have two datasets for reasons of NAs: datasetA N=22 and T = 24 (1995-2018), datasetB N = 31 and T = 15 (2004-2018). In both cases the results I get are similar, I think it is not so much a problem of number of individuals, but to use the right method, i.e. between a static (fixed vs random) or dynamic (GMM) model. $\endgroup$
    – UzbeKistaN
    Sep 28, 2020 at 14:32
  • $\begingroup$ Let me clarify. After your results come in, do you wish to make statements (generalize) about countries outside of your sample? Or, do you only care about European countries? $\endgroup$ Sep 28, 2020 at 14:43

2 Answers 2

3
$\begingroup$

My analysis concerns a macroeconomic study and as often happens in these cases (I would not be wrong but they are commonly called "macro-panel" or "wide-panel").

I have never heard of the term "wide panel" before. I assume you are referring to a dataset with some fixed $N$ and small $T$, thus giving the appearance of a wider data frame. I would argue "macro panel" is a more apt description, where you have a reasonably large number of countries over many years (e.g., 20 years or more). The term "macro panel" is used quite frequently in Chapter 12 of Badi Baltagi's Econometric Analysis and Panel Data.

Using static panel models, the literature suggests using fixed-effect models in such cases, but in the models I am analyzing the Hausman test tells me the opposite, preferring the random-effect models. I don't understand why I get this result, I'm starting to think that it is due to the presence of variables that change little or no at all over time, and this generates problems in fixed models.

Results from a Hausman test suggest random effects. In short, your unique errors are not correlated with your regressors. You might favor a random effects estimator if some of these time-invariant or "slow moving" regressors are of substantive interest. In a fixed effects model, all time-constant variables included in your model will be collinear with the country-specific effect and summarily dropped; this is because a fixed effects estimator only uses the time-series variation from within each country. A random effects estimator, on the other hand, will exploit some "between unit" (i.e., cross-country) variation, and thus any time-constant variables may remain. In fact, the random effects estimator is akin to a weighted average of the "within" and "between" estimators.

You also state that the presence of omitted, time-constant confounders "generates problems in fixed models." I disagree with this statement. The attractiveness of fixed effects estimators is they will 'partial out' the effects of all time-constant variables—even those you have not explicitly measured (or even thought of). If you proceed with a random effects model, then your country-specific effect is treated as random and is assumed to be uncorrelated with your explanatory variables. Is this a reasonable assumption in your setting? In practice, this assumption is often incorrect. It is unlikely that the true correlation between the unit (i.e., country) effects and your covariates is exactly zero. Quoting from Clark & Linzer (2015):

[I]f the Hausman test fails to reject the null hypothesis of orthogonality, it is most likely not because the true correlation is zero....Rather, it is likely that the test has insufficient statistical power to reliably distinguish a small correlation from zero correlation....Of course, in many cases, a biased (random-effects) estimator can be preferable to an unbiased (fixed-effects) estimator if the former provides sufficient variance reduction over the latter. The Hausman test does not help evaluate this trade-off."

I should also note that the advice you receive from others might be discipline-specific. I once conferred with an epidemiologist on a project and he was more than happy to disregard the results from a Hausman test. Applied econometricians, on the other hand, might be more predisposed to let the results from a Hausman test guide their approach. I'm an expert in neither field of study, so I shouldn't speak for entire disciplines. Maybe one of them will jump in and set me straight on that one.

It is difficult to offer guidance without more detail about the theoretical model under consideration. In the comments I drew your attention to the notion of generalizability outside of your sample of countries. It might be more appropriate to treat the unit-specific effect as "random" if you're sampling a subset of units from a larger, unobserved population. The units can be individuals, hospitals, precincts, counties, et cetera. Sometimes we are interested in the units outside of our sample, and other times we only care about the sample at hand. I think this is important to consider in your situation. Suppose you wish to survey the attitudes, beliefs, and perceptions of college students about some important social issue over time across a diverse range of campuses in the United States. Scarce funding for the project limits your ability to obtain repeated measures across time at all universities, so you decide to observe a subset of campuses instead. If your aim is to generalized to all campuses in the United States (or any broader campus population outside of your sample), then treating the "campus" as random might be preferred. Or, maybe you already sampled all observations from the relevant population. There are many examples of this in the real world.

For example, suppose I was hired to evaluate a new policy implemented by a large metropolitan police department. A subset of law enforcement districts implement the policy and others do not. Now suppose police officials want to know if the new policy/directive was effective at lowering the crime rate. To begin, I might survey all districts that comprise that agency before and after the policy exposure period. In this case, I'm sampling the entire population of law enforcement units, which include all treated and untreated districts. Again, I only care about the districts comprising one large metropolitan agency. If I only wish to make statements about that particular agency, then I might proceed with a fixed effects estimator, or some derivative of it. Now suppose I sample a much broader array of police districts in a particular geographic region of the United States and I want to make statement about all districts in the entire country. In this setting, it might want to treat the district as a random effect.

In your setting, it appears you're only interested in European countries. I don't presume your results will guide policy or be applicable to Asian markets—or maybe they will. As I see it, you're only sampling a subset of the 44 European countries (though to be precise, it might be 49 countries if you're considering the Eurasian Caucasus region as part of the European continent). As you already noted, your results shouldn't change much if you obtained the full population of European countries. If you're only interested in the subset of European markets, then maybe modeling the country effect as 'fixed' is the better way to go.

Therefore, given the diagnostic problems I am having with static models, I wonder if it is more appropriate to use dynamic models, or to stay on fixed / random models taking the necessary precautions, and on the basis of what I can evaluate this choice, comparing the results obtained with the two different approaches (static vs dynamic).

What diagnostic problems did you run into? Just because the results of a Hausman test suggest random effects doesn't mean you have a problem. Running a "static" random effects model is perfectly acceptable in my estimation.

It is also reasonable for you to explore a dynamic model. A very good predictor of behavior or economic activity at time $t$ is the period $t-1$. But a dynamic model introduces a new set of problems. To be clear, by "dynamic" I mean including a lagged dependent variable(s) on the right-hand side of your equation. I would caution you against modeling "country" as either fixed or random while also including a lagged dependent variable as a predictor. The lagged version of your outcome will be correlated with the random effect that is part of your error term.

I also encourage you to read Paul Allison's blog in regard to the problems associated with using a lagged outcome as a predictor in panel data models. The discussion is quite interesting. In sum, there is no correct answer to your question. I wouldn't stray too far from other applied work addressing your specific research question. Here is a recent paper by Leszczensky & Wolbring 2019 that offers some alternative approaches to addressing reverse causality in panel data contexts.

I have found research regarding my work and most of them are based on dynamic models, using generalized method of moments (GMM) with a lagged dependent variable as a regressor.

You didn't cite any empirical work in your question but there is strong literature out there which shows that the generalized method of moments (GMM) estimator can generalize to panel data with spatially and temporally correlated error components. I'm not sure what software you're working with, but you could run a dynamic panel model using GMM in R fairly easily. The GMM estimator is provided by the pgmm() function from the package plm in R. It’s main argument is a dynformula which describes the variables of the model and the lag structure (see here for more information). I believe this function mirrors xtabond2 from Stata. I can't speak for all software packages but I believe you could implement a model fairly easily based upon the associated documentation.

I hope this helps!

$\endgroup$
0
$\begingroup$

Thanks for the answer and for editing my post, I recognize that I have many gaps in English. Thanks also for the references you recommended. I will give them a look

I have never heard of the term "wide panel" before. I assume you are referring to a dataset with some fixed N and small T, thus giving the appearance of a wider data frame. I would argue "macro panel" is a more apt description, where you have a reasonably large number of countries over many years (e.g., 20 years or more). The term "macro panel" is used quite frequently in Chapter 12 of Badi Baltagi's Econometric Analysis and Panel Data.

Yes, by "wide panel" I was referring to a dataset with a large N and a short T. Reading in other forums/sites some abused this term, maybe erroneously, which was also unknown to me. However, in these days I have made some adjustments and ultimately the dataset I will work on will be composed of 30 countries in 15 years.

For the question related to the Hausman test and the difference between fixed and random effects, in relation to my dataset and my analysis, I had some doubts about the results precisely because the European countries I'm analyzing are the only ones I have available for the data I need, probably also because in all other countries there is not a sufficiently developed economic-financial context.

To be more specific, my work is to analyze the life insurance market, in particular how demand has evolved in Europe in relation to macroeconomic-financial and demographic variables. Therefore the fact that I have found 30 countries I think is very satisfactory.

So, returning to the concept of sampling and the choice of the fixed/random model, as you said, as were my expectations before the results I obtained, in my context of analysis the fixed effects should be the most appropriate.

Being a novice in panel econometrics, my benchmark was the Hausman test, but now I don't know how much to trust. I can try to remove those quasi-invariant variables over time, but I would consider them important because they are mostly demographic variables (life expectancy, population structure indexes and employment/unemployment rate. I have several models because I am implementing a model selection based on some measures of goodness of fit: adjusted R-square, RMSE and AIC). Without them I would be left with a model that would explain little, both from an interpretative and an R-squared point of view (I know that R-squared is not an absolute measure to evaluate a model, but if its value is very low, max 0.15, I think I could improve it by adding some regressors).

This is also the reason why maybe in this case a static model has several limits with these variables, which has led the literature (if necessary I can also cite some sources) to use GMMs for dynamic models.

For my analysis I'm using R and the plm package. I'm reading the vignette you suggested and I'm also reading the book "Panel Data Econometrics with R" written by the same authors. I have already tried some GMM model with the pgmm function but not knowing the theory it was just an experiment. I wouldn't want to go off-topic but doing the summary of the pgmm models I noticed some things, for example some tests and the fact that the R-square is not reported (as said if I have to do a model selection I need some performance measure to compare the different models. Maybe if I have to work on GMMs with R I will look for answers on Stackoverflow).

What diagnostic problems did you run into? Just because the results of a Hausman test suggest random effects doesn't mean you have a problem. Running a "static" random effects model is perfectly acceptable in my estimation.

With diagnostic problems I meant serial correlation and cross-sectional dependence, with which I solved using the robust covariance matrix

$\endgroup$
3
  • $\begingroup$ I’m glad you found my answer helpful. In the future, try not to respond to my answer like this; use the comment section instead. Please try to drill down on exactly what follow-up questions you might have and I will update my answer accordingly. $\endgroup$ Oct 2, 2020 at 21:01
  • $\begingroup$ I'm sorry, next time I will use the comment section. I read the article by Clark & ​​Linzer that you suggested to me and it was very useful. In the article they also highlight that that when there are few observations per unit, or if a regressor varies little within each unit, the FE model tends to have a high variance, which increases the standard errors of estimates. This is connected to the results I get with the Hausman test, that prefers the RE, even if it could be biased and incoherent with the type of analysis (I'm referring to the matter of sampling we talked about). $\endgroup$
    – UzbeKistaN
    Oct 5, 2020 at 20:58
  • $\begingroup$ Therefore, all these drawbacks are pushing me more and more to try a different approach, i.e. using a dynamic panel with GMMs. I think that if other researchers who have done a similar work have adopted GMMs there is a reason. Now my doubts concern how to do a model selection with GMM, i.e. how to evaluate two or more models with different regressors, since the output of the pgmm function does not give me any measure of goodness of fit. For example, I would like to calculate R-squared, RMSE and AIC if it's possible. Could you help me? Or are there other measures more suitable for these models? $\endgroup$
    – UzbeKistaN
    Oct 5, 2020 at 21:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.