Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • "too many base levels specified" after -suest-

    Hi all,

    I am using -suest- to compare coefficients of the same variable across two logit model (using -test-). My models include nine year-dummies and many other variables. The first model is named "All_es" while the second one is named "All_ls". I tried to run suest but I got the following message:



    Code:
    suest All_es All_ls
    which gives me the following error;


    too many base levels specified
    r(198);
    Without these year dummies, I won't get this message. But, I need these dummies for correct specifications of my two models (i.e., "All_es" and "All_ls).

    Any solution? I am using -suest- to be able to use -test- command afterward. -test- runs a chi-squared test to compare coefficients. How can I do this manually (my models have the same number of variables. They are run on two different sub-samples)?


    Thanks,
    Navid

  • #2
    Do I understand correctly that the two models have exactly the same variables (not just the same number of variables, but actually the same variables)? If so, what you can do is run it all in a single model with interactions. So, I assume there is a variable in your data that distinguishes the two subsamples of the different models. Let's call that variable subsample, coded 0 for one of the subsamples and 1 for the other. Your model is something like -logit y x1 x2 x3 x4-. For illustrative purposes I'll assume x1 and x2 are continuous variables and x3 and x4 are discrete. Then run:

    Code:
    logit y i.subsample##(c.(x1 x2) i.(x3 x4))
    In the output, the coefficients of the interaction terms (that will look like 1.subsample#x1, or 1.subsample#3.x3, etc.) are estimators of the difference in the logistic regression coefficients between the two models, along with standard errors, confidence intervals, and, if you like, p-values.

    Comment

    Working...
    X