Announcement

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

  • Change consecutive model number in esttab command

    Hi all,
    I've been searching for the solution for long, but I haven't got one. I used esttab to export regressions to a tex file. However, I need the model numbers to start from 11 instead of 1. My codes are below. I would like to model numbers to be (11) (12) (13) (14). Thank you in advance!!

    esttab reg1 reg2 reg3 reg4
    using "table.tex", b(a2) se(a2) se star(* 0.10 ** 0.05 *** 0.01) ///
    mgroups("group1" "group2", ///
    pattern(1 0 1 0) ///
    prefix(\multicolumn{@span}{c}{) suffix(}) span erepeat(\cmidrule(lr){@span})) ///
    mtitles("Depvar1" "Depvar2" "Depvar1" "Depvar2") ///
    label replace

  • #2
    Welcome to Statalist. In the future, please post Stata related questions in the General forum. esttab is from the Stata Journal/ SSC (FAQ Advice #12). With 9 or less models, you can

    Code:
    sysuse auto
    eststo m1: reg mpg price weight
    esttab m1 m1 m1 m1,  numbers("(1" ")")
    Res.:

    Code:
    . esttab m1 m1 m1 m1,  numbers("(1" ")")
    
    ----------------------------------------------------------------------------
                         (11)            (12)            (13)            (14)  
                          mpg             mpg             mpg             mpg  
    ----------------------------------------------------------------------------
    price          -0.0000935      -0.0000935      -0.0000935      -0.0000935  
                      (-0.57)         (-0.57)         (-0.57)         (-0.57)  
    
    weight           -0.00582***     -0.00582***     -0.00582***     -0.00582***
                      (-9.42)         (-9.42)         (-9.42)         (-9.42)  
    
    _cons               39.44***        39.44***        39.44***        39.44***
                      (24.32)         (24.32)         (24.32)         (24.32)  
    ----------------------------------------------------------------------------
    N                      74              74              74              74  
    ----------------------------------------------------------------------------
    t statistics in parentheses
    * p<0.05, ** p<0.01, *** p<0.001

    Comment


    • #3
      Thanks a lot! I'll post to the right place next time.

      Comment

      Working...
      X