Announcement

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

  • Export tables horizontally to an excel file

    Hi,

    I would like to know if there is a way to append a new estimation table horizontally instead of vertically. For example, how can I append the table with the results from the "lifeexp" regressions next to the table with the results from the "auto" regressions and see both tables side by side in the same excel sheet.

    Code:
    sysuse auto
            
    regress price weight mpg        
    eststo 
            
    regress price weight mpg foreign
    eststo
            
    esttab using "...\Table1.csv", label
    
    sysuse lifeexp, clear 
    eststo clear
    reg lexp gnppc 
    eststo
    reg lexp gnppc safewater 
    eststo
    
    esttab using "...\Table1.csv", label append

  • #2
    Perhaps this accomplishes what you seek?
    Code:
    eststo clear
    
    sysuse auto, clear
    regress price weight mpg        
    eststo
    regress price weight mpg foreign
    eststo
            
    sysuse lifeexp, clear
    regress lexp gnppc
    eststo
    regress lexp gnppc safewater
    eststo
    
    esttab using "Table1.csv", label replace
    Last edited by William Lisowski; 18 Jan 2017, 14:50.

    Comment


    • #3
      Thanks William for your input. This is very close to what I want to get.
      I would like to have the first table (using lifeexp.dta) separated from the second one (using auto.dta).
      So the variables in the second regression do not appear below the variables of the first regression.
      Any idea how to get this ? Thanks everyone.

      Regards,
      Celia P.

      Comment

      Working...
      X