Announcement

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

  • xtrifreg omitted coefficients and post-estimation graph

    Dear all,

    I am using the command xtrifreg to perform unconditional quantile regression to identify gender gaps at the mean and extreme levels of the dependent variable. My dataset is in long format, I have multiple observations for each individual, and individual-subject uniquely identifies observations.
    I run seperate models for each subject and, therefore, I use xtrifreg in a loop which repeats it for 10 subjects (=j) and 6 grades (g). The fixed effects are at the school level, and the standard errors are cluster-robust (by default).
    I use the following code to perform this:

    Code:
    forv j= 1/10 {
     forv i=25(25)75 {
       forv g = 1/6 {
    xtrifreg diff female $controls if sub==`j' & agrade==`g', fe i(ssid) q(`i')
    }
    }
    }
    The regression performs fine in most cases, but in some cases I get omitted coefficients and standard errors. Do you know why that might be? Could it be because the values are too small?

    In addition, I would like to plot the coefficients instead of showing them in a table but I could not find a suitable command. Ideally, I would like to have one graph for each subject and each graph to plot the coefficients across quantiles for each grade (i.e. 6 lines in one graph, 10 graphs in total). I would be also keen to use deciles instead of quantiles, if the omitted coefficient problem is resolved.

    I hope my explanation is clear.
    Thank you so much! Your help will be appreciated a lot.

  • #2
    Hi Konstantina
    a couple of suggestions.
    1) perhaps you would rather use -rifhdreg-, which is more general than xtrifreg.
    2) if you have cases of committed coefficients and SE it may be that particular regression is illconditioned. Namely that your dp variable is flat or has very little variation, or that your sample is too small to get effects for your dependent variables (this requires looking into the X's distribution for those cases)
    3) if you use rifhdreg, you could use qregplot afterwards to plot the coefficients of interest.
    4) If you want to use the true gender gap , you may need to use the option over()
    rifhdreg wage female $controls, over(female) rif(q(10))
    hth

    Comment


    • #3
      Hi Fernando,
      Thank you for your useful suggestion, I will try with rifhdreg and then use qregplot to plot the coefficients.
      Is it possible to plot the coefficients from more than one regression in the same graph using qregplot? That is, to have one line from each regression in the same graph.

      Thanks!
      Konstantina

      Comment

      Working...
      X