Suppose we are running a model, let's say a linear regression model or a logistic regression. Suppose also that we have gathered data for three cities: City A (4000 surveys), City B (5000 surveys) and City C (4000 surveys).

We are interested in the outcome variable Y and we have a set of regressors X (not including the city).

What would be the best way to fit the model?

  • a model with city fixed effects: Y = X + City_B + City_C (City_A is used as the reference variable); or
  • fit three independent models (one for each city)

Les's also assume that we want to add some interactions between the cities and some of regressors. This question comes from a project I have been working on. My rationale so far has been that, given that I expect to add many interactions and that the sample size is relatively large for each city, then fitting independent models could give better estimates.

  • 1
    $\begingroup$ Either of those models could be better; depends on whether there are significant interactions between the city and X (aka whether the true slope $\beta$ is different from city to city). This is because the independent model may be viewed as one unified model with differing coefficients for each city. We could go in between these two approaches as well by using a hierarchical model that allows some information exchange between cities. $\endgroup$ Aug 2 at 2:27
  • 1
    $\begingroup$ This is explained well in Gelman and Hill "Data Analysis using Regression and Multilevel/Hierarchical Models", particularly Ch 11 "Multilevel structures". The example given is even about cities. You can find a pdf online. $\endgroup$ Aug 2 at 3:21


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.