Announcement

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

  • Significance level in Oaxaca decomposition

    Hi,

    I would like to add significance level stars into the coefplot after doing a three-fold Oaxaca decomposition.
    I think I am not saving the coefficients correctly into 'pval' .
    Can I get some help please?

    Thank you!

    Code:
    coefplot (., drop(endowments:* coefficients:* interaction:*)),    ///
    recast(bar) barwidth(0.5) citop ciopts(recast(rcap) color(black)) ///
    byopts(cols(1)) xline(0, lpattern(dash)) xlabel(, grid glstyle(minor_grid) glpattern(dash)) ///
    coeflabels(group_1 = "High" group_2 = "Low" difference = "Difference" endowments="Endowments" coefficients="Coefficients" interaction="Interaction") ///
    mlabel(cond(@pval<.001, "<0.001" + "***", ///
    cond(@pval<.01, string(@pval,"%9.3f") + "**", ///
    cond(@pval<.05, string(@pval,"%9.3f") + "*", ///
    string(@pval,"%9.3f"))))) drop(_cons) scheme(s1color) ///
    note("p-values shown alongside markers" "* p<0.05, ** p<0.01, *** p<0.001")

Working...
X