Announcement

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

  • How can I add the the decomposition of the R² in "between" and "within" to a a table (xtreg) ?

    I am studying the relationship between university rankings (dependant variable) and academic freedom (independant variable). During my research, I found out that I get much more consistent results if I use cross sectional databases instead of panel databases.

    I want to explain this in my report, but also want to show some proof of this. When using the
    Code:
    xtreg
    command, I get these results :

    Click image for larger version

Name:	Statalist.PNG
Views:	1
Size:	21.6 KB
ID:	1713884


    I want to draw you attention on the part circled in blue. This show a decomposition of the R² in "within" (time series dimension of the data) and "between" (cross-sectional dimension of the data). Showing this in my LaTeX regression table could constitute proof that a big part of the variance of my model is explained by the cross-sectionnal aspect of my data, rather than the time series aspect.

    The problem is, I don't know how I could include this in the regression table. I know how to use
    Code:
    esttab
    and
    Code:
    outreg
    , but I don't know if there are any options for these commands to include this particular information in the final table. Worst case scenario, I can always add it manually in LaTeX, but if there is another way to do it, I would prefer it.

    Attached Files

  • #2
    estout and outreg2 are from SSC (FAQ Advice #12). Run

    Code:
    ereturn list
    after the regression. The statistics should be stored as "r2_w" and "r2_b".

    Comment


    • #3
      Thank you very much !

      Comment

      Working...
      X