Announcement

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

  • Create Excel/Word Ouput after Regression

    Hey!

    I like to generate a doc-ouput of my regression. Unfortunately my asdoc command gets only an error

    asdoc xtreg f. emission_intensity sum_environmental_metric firm_size profitability leverage sales_growth rnd_expenditure board_size board_independence board_outsider i.year, fe vce(robust), save(xx.doc)

    The error that comes up: <istmt>: 3499 func_detailed_reg() not found


    Somebody knows why? Used it before and worked perfectly.
    Thanks a lot!

    Last edited by albert master; 09 Apr 2022, 08:11.

  • #2
    The output of help asdoc - a community contributed command - does not suggest that it works with any regression command other than reg.

    Comment


    • #3
      Originally posted by William Lisowski View Post
      The output of help asdoc - a community contributed command - does not suggest that it works with any regression command other than reg.
      That is strange as it worked with my fixed effect regressions before, so I was just lucky?

      what other command can you recommend?

      Comment


      • #4
        I agree, experimentation showed me that it xtreg does work with asdoc.

        The following demonstrates that the missing function is part of the asdoc installation. Before installing asdoc I get the same error message you did. After installing asdoc the function is found and the error confirms that I haven't the faintest idea how the function is used. And then I proceed to demonstrate that asdoc xtreg is successful with a model simpler than your but with the same options.
        Code:
        . mata func_detailed_reg()
                         <istmt>:  3499  func_detailed_reg() not found
        r(3499);
        
        . net install asdoc.pkg, from(http://fintechprofessor.com)
        checking asdoc consistency and verifying not already installed...
        installing into /Users/lisowskiw/Library/Application Support/Stata/ado/plus/...
        installation complete.
        
        . 
        . mata func_detailed_reg()
             func_detailed_reg():  3001  expected 23 arguments but received 0
                         <istmt>:     -  function returned error
        r(3001);
        
        . webuse grunfeld
        
        . xtset
        
        Panel variable: company (strongly balanced)
         Time variable: year, 1935 to 1954
                 Delta: 1 year
        
        . asdoc xtreg mvalue invest i.year, fe vce(robust), save(xx.doc)
        (File xx.doc already exists, option append was assumed)
        
        Fixed-effects (within) regression               Number of obs     =        200
        Group variable: company                         Number of groups  =         10
        
        R-squared:                                      Obs per group:
             Within  = 0.5383                                         min =         20
             Between = 0.8572                                         avg =       20.0
             Overall = 0.6801                                         max =         20
        
                                                        F(9,9)            =          .
        corr(u_i, Xb) = 0.6904                          Prob > F          =          .
        
                                       (Std. err. adjusted for 10 clusters in company)
        ------------------------------------------------------------------------------
                     |               Robust
              mvalue | Coefficient  std. err.      t    P>|t|     [95% conf. interval]
        -------------+----------------------------------------------------------------
              invest |   1.717841   .1408215    12.20   0.000     1.399281    2.036402
                     |
                year |
               1936  |   322.5244   156.6209     2.06   0.070     -31.7767    676.8255
               1937  |   559.3822   249.6255     2.24   0.052    -5.310045    1124.074
               1938  |   131.4099   101.7075     1.29   0.229    -98.66848    361.4883
               1939  |   359.4182   148.3617     2.42   0.038     23.80065    695.0358
               1940  |   356.9408   149.9629     2.38   0.041     17.70116    696.1803
               1941  |    265.428   125.8837     2.11   0.064     -19.3407    550.1967
               1942  |   87.62209   67.00266     1.31   0.223    -63.94845    239.1926
               1943  |   210.3145   86.37141     2.44   0.038     14.92884    405.7003
               1944  |   237.5371   100.0648     2.37   0.042      11.1748    463.8994
               1945  |   344.3146   143.7634     2.40   0.040     19.09921      669.53
               1946  |   344.2699   132.8852     2.59   0.029     43.66265    644.8772
               1947  |   92.03748   50.82408     1.81   0.104    -22.93456    207.0095
               1948  |   50.01684   70.70545     0.71   0.497      -109.93    209.9637
               1949  |   95.84998   47.29136     2.03   0.073     -11.1305    202.8305
               1950  |   135.0513    64.8218     2.08   0.067    -11.58584    281.6884
               1951  |   282.7271   103.0192     2.74   0.023     49.68161    515.7727
               1952  |   287.0239   106.1683     2.70   0.024     46.85454    527.1932
               1953  |   421.8682   166.9061     2.53   0.032     44.30049     799.436
               1954  |   385.1248   160.9841     2.39   0.040     20.95346    749.2961
                     |
               _cons |   582.5049   93.89341     6.20   0.000     370.1033    794.9066
        -------------+----------------------------------------------------------------
             sigma_u |  1026.8384
             sigma_e |  250.34154
                 rho |  .94389698   (fraction of variance due to u_i)
        ------------------------------------------------------------------------------
        Click to Open File:  xx.doc
        
        .
        So I recommend you unistall your copy of asdoc,
        Code:
        ado uninstall asdoc
        and then install the latest version using the same command I used. That should solve your problem.

        Comment

        Working...
        X