Announcement

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

  • Making Regression Tables fit using the esttab command

    Hello All,

    I am in the midst of running approximately 8 different regression specifications, to answer the same quesiton. As such, I would ideally like them all to be displayed in the same output table.
    Basically, I run the following code:

    Code:
    eststo clear
    eststo: xi: quietly regress y x
    .
    .
    
    eststo: xi: quietly regress y x i.year i.country
    esttab, indicate("Country Effects=_Iisocode2*" "Year Effects=_Iyear*") compress abbrev
    This code just displays all the output in a very jumbled manner on the Stata screen. Are there any fixes to this using the esttab command (either directly to be displayed on stata or on latex?)

    Thanks!
    Chinmay


  • #2
    Esttab can send your tables to word documents or Latex, or in a combined view on screen


    Code:
    sysuse auto, clear
    reg price mpg rep78 headroom trunk weight
    eststo Model1
    reg price mpg rep78 headroom trunk weight
    eststo Model2
    reg price mpg rep78 headroom trunk weight
    eststo Model3
    reg price mpg rep78 headroom trunk weight
    eststo Model4
    *to stick tables in word file:
    esttab Model1 Model2 Model3 Model4 using example.rtf, replace mtitle ("Model1" "Model2" "Model3" "Model4")
    *to stick tables in tex file:
    esttab Model1 Model2 Model3 Model4 using example.tex, replace mtitle ("Model1" "Model2" "Model3" "Model4")
    *to show in Stata output screen:
    esttab Model1 Model2 Model3 Model4, replace se label mtitle ("Model1" "Model2" "Model3" "Model4")

    Comment


    • #3
      Thank you for your reply. Unfortunately, given that I have 9 regressions, the output tables don't fit on either LateX or Stata. For instance, the 3rd option does not work with 8 regressions, as the output appears quite jumbled . Is there any way so as to compress the output table so that it fits on a single page?

      Comment


      • #4
        If your screen or the page your outputting to isnt wide enough, then either:
        - use a wider page (landscape view)
        - use two pages, i.e., run the esttab for 5 models, output it, then for the other four.

        Same applies to Stata output screen. You can widen the output screen a bit by dragging its borders, but otherwise esttab in two blocks would work?

        Comment


        • #5
          I have done it in two blocks, but the regressions alongside each other are preferable. I don't think there's a solution on Skype itself, but I should in principle be able to fit it in a single table on Latex. Thanks anyway!

          Comment


          • #6
            This is more of a question on how to use Latex. I think the same principle applies, use two pages, or use a landscape page: https://tex.stackexchange.com/questi...etables/345484

            Comment

            Working...
            X