Announcement

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

  • Sub sample analysis with xtnbreg

    Dear fellow Stata-users,

    To test whether my variable M is moderating the relation between X and Y I want to use a sub sample analysis. I have a panel dataset (11 years, 160 firms, 1600 observations). My dependent variable is an overdispersed count variable so I obt for the use of xtnbreg, fe (as the data characteristics and the Hausman test indicate the use of FE, rather than RE).

    Xtnbreg does not seem to allow the following method:

    Code:
    xtset ID year
    xtnbreg Y X M Controls if M == high, fe
    store estimates high
    xtnbreg Y X M Controls if M == low, fe
    store estimates low
    suest high low
    then
    Code:
    test [low_mean]X=[high_mean]X
    or
    Code:
    test [low_mean]X-[high_mean]X=0
    then check for significant or not.

    Unfortunately, suest and xtnbreg don't (seem) to cooperate..
    Does someone have an idea on how to perform the sub sample analysis with xtnbreg? (or knows where I can find the answer to my question?)

    Note: I do not want to conduct a moderated regression analysis with an interaction term. If necessary, additional information can be provided of course.

    Thanks in advance!

  • #2
    You can often estimate sub-sample parameters by interacting dummies for the subsamples with the x's of interest. You'll want to use factor variable notation since it makes the margins analysis easy.

    Comment

    Working...
    X