Announcement

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

  • Pratap Pundir
    replied
    Originally posted by Attaullah Shah View Post
    drop(i.qtr) should be included either in each line or in the last line.
    Yes, the new code drops the quarters. Thanks! Perhaps include this info in the documentation.

    Originally posted by Attaullah Shah View Post
    I had asked for the data set, however, you have posted the do file.
    As mentioned in a previous message

    Originally posted by Pratap Pundir View Post
    The data set is from World Bank, being pulled directly.
    Specifically, line 21
    Code:
    wbopendata, indicator(EN.ATM.CO2E.KT;SP.POP.TOTL;NY.GDP.PCAP.KN;AG.LND.FRST.ZS;AG.LND.AGRI.ZS) long clear
    gets data directly from World Bank. There is no initial data file to import aside from this...

    Leave a comment:


  • Attaullah Shah
    replied
    Rodrigo Badilla As promised, all future additions will be made to asdox, please keep visiting this page for updates. https://fintechprofessor.com/stata-programs/asdocx/

    Leave a comment:


  • Attaullah Shah
    replied
    Pratap Pundir My mistake, not asdoc's in post #15. The code drop(i.qtr) should be included either in each line or in the last line. Following is the correct code.
    webuse lutkepohl2
    Code:
    tsset  
    global wordfile Regressions  
    asdoc reg dln_inv dln_inc L(0/2).dln_consump i.qtr, add(Year FE, Yes) save($wordfile) nest cnames(CS 2Lag) replace  
    asdoc reg dln_inv dln_inc L(0/2).dln_consump, add(Year FE, No)  save($wordfile) nest cnames(CS 2Lag) drop(i.qtr)
    Second, I had asked for the data set, however, you have posted the do file.

    Leave a comment:


  • Rodrigo Badilla
    replied
    Dear Dr,

    And for Anova?...
    Regards

    Leave a comment:


  • Pratap Pundir
    replied
    P.S. The code posted by you
    Code:
    webuse lutkepohl2  
    tsset  
    global wordfile Regressions  
    asdoc reg dln_inv dln_inc L(0/2).dln_consump i.qtr, add(Year FE, Yes) drop(i.qtr) save($wordfile) nest cnames(CS 2Lag) replace  
    asdoc reg dln_inv dln_inc L(0/2).dln_consump, add(Year FE, No)  save($wordfile) nest cnames(CS 2Lag)
    does not return an error, but doesn't work as expected either. For one, `drop(i.qtr)` doesn't work - the exported Word file lists quarters 3 to 91, regardless.
    Last edited by Pratap Pundir; 19 Mar 2019, 05:15.

    Leave a comment:


  • Pratap Pundir
    replied
    Please find attached my code. The data set is from World Bank, being pulled directly.

    Code:
    which asdoc
    returns
    Code:
    Version 2.3.3.3: Changes made March 6, 2019
    Attached Files

    Leave a comment:


  • Attaullah Shah
    replied
    Pratap Pundir Please confirm that you have the latest version. It should be Version 2.3.3.3
    Code:
    which asdoc
    will show the version.
    If the version is up to date, then please either post a sample data set that produces the error or send it to me at [email protected]
    I checked your example on the following dataset and it works fine.

    Code:
    webuse lutkepohl2
    tsset
    global wordfile Regressions
    asdoc reg dln_inv dln_inc L(0/2).dln_consump i.qtr, add(Year FE, Yes) drop(i.qtr) save($wordfile) nest cnames(CS 2Lag) replace
    asdoc reg dln_inv dln_inc L(0/2).dln_consump, add(Year FE, No)  save($wordfile) nest cnames(CS 2Lag)
    Click image for larger version

Name:	Capture.PNG
Views:	1
Size:	38.0 KB
ID:	1488868

    Leave a comment:


  • Pratap Pundir
    replied
    I suspect this has to do more with the
    Code:
    add(Year FE, Yes)
    in the nesting situation, than with anything else.
    So, I guess my question should be - if I am adding row info, how do I nest the regression tables?

    In your example, you have used the exact same options
    Code:
    add(Year dummies, no)
    in consecutive nesting regressions. But it's clearly not working in my case.

    Leave a comment:


  • Pratap Pundir
    replied
    Code:
    asdoc reg d_ln_co2 l(0/2).d_ln_gdp i.year, vce(cluster country) add(Year FE, Yes) drop(i.year) save($wordfile) nest cnames(FD 2Lag)
    returns
    func_nested_reg(): 3301 subscript invalid
    <istmt>: - function returned error
    Code:
    reg d_ln_co2 l(0/2).d_ln_gdp i.year, vce(cluster country)
    runs fine.
    Code:
    asdoc reg d_ln_co2 d_ln_gdp i.year, vce(cluster country) add(Year FE, Yes) drop(i.year) save($wordfile) nest cnames(FD)
    also runs fine
    Last edited by Pratap Pundir; 18 Mar 2019, 13:10.

    Leave a comment:


  • Attaullah Shah
    replied
    Pratap Pundir These options will be included in the premium version, called asdocx. For updates, please visit this page
    https://fintechprofessor.com/stata-programs/asdocx/

    Leave a comment:


  • Pratap Pundir
    replied
    Thank you!
    Are the following also already available?
    Originally posted by Pratap Pundir View Post
    it would be nice if asdoc could:
    1. Export to docx, instead of doc
    2. Send graphs to the Word document. Internal command putdocx already does this, but if I am using asdoc, I don't expect to create a separate document with putdocx just for the charts...
    3. Support for UTF8. At the moment, any letters with accents get messed up, and text export gets confused by common text symbols such as ' and )

    Leave a comment:


  • Attaullah Shah
    replied
    Pratap Pundir These options are available in asdoc, you can read section 4. Regressions
    Code:
    help asdoc
    In the following examples, I am using option add() to add additional text, keep() to keep only relevant variables and cnames() to change the column headers. `Option fe and re are options of xtreg command
    Code:
    webuse grunfeld
    asdoc xtreg invest mvalue kstock , fe add(Year dummies, no) nest replace cnames(FE)
    asdoc xtreg invest mvalue kstock i.year , re add(Year dummies, Yes) nest cnames(RE) keep(mvalue kstock )
    Last edited by Attaullah Shah; 16 Mar 2019, 02:30.

    Leave a comment:


  • John Riveros
    replied
    Greetings Dr Shah, VECM and VAR results cannot be displayed so easily in the current versions. It would be extremly useful to add this feature to asdoc as it could be able to show a decent output from VAR and VECM estimations.

    Leave a comment:


  • Rodrigo Badilla
    replied
    Dear Attaullah Shah

    Thanks for asdoc!. I am working with ANOVA analysis.
    Lamentably when I try to get an anova table with asdoc I just get a regression table with p-value to each level from independient variable and not like stata result.
    I wonder if exist some method to get a similar result to Anova table from stata. Example:

    Code:
    webuse lifeexp.dta, clear
    asdoc anova popgrowth  region
    stata result

    Code:
                               Number of obs =      68     R-squared     =  0.4345
                               Root MSE      = .710934     Adj R-squared =  0.4171
    
                      Source |  Partial SS    df       MS           F     Prob > F
                  -----------+----------------------------------------------------
                       Model |  25.2441263     2  12.6220631      24.97     0.0000
                             |
                      region |  25.2441263     2  12.6220631      24.97     0.0000
                             |
                    Residual |  32.8527857    65  .505427472   
                  -----------+----------------------------------------------------
                       Total |  58.0969119    67  .867118089
    With asdoc:
    Code:
    Regression results   
    popgrowth Coef. St.Err. t-value p-value [95% Conf Interval] Sig
    1b.region 0.000 . . . . .
    2.region 1.168 0.218 5.35 0.000 0.732 1.604 ***
    3.region 1.405 0.249 5.64 0.000 0.908 1.902 ***
    Constant 0.525 0.107 4.90 0.000 0.311 0.739 ***
    Mean dependent var 0.972 SD dependent var 0.931
    R-squared 0.435 Number of obs 68.000
    F-test 24.973 Prob > F 0.000
    Akaike crit. (AIC) 149.508 Bayesian crit. (BIC) 156.166
    Thanks in advance
    Regards
    Rodrigo

    Leave a comment:


  • Pratap Pundir
    replied
    I mean things such as longitudinal regressions (e.g. fixed effects) with xtreg.

    The output is exported, but not in publication ready format as promised. For one, in fixed effects models, what's the point of putting a constant in the table? Also, the table should indicate which fixed effects (e.g. in case of World Bank data, often countries and years are included). Similarly, for the R^2, a publication-ready table needs to show the isolated impact of the x variable, separate from the fixed effects. This is kind of what I expect to see when sending results of a fixed effects model to nested Word table (not talking about the aesthetics, but the content):
    Click image for larger version

Name:	asdoc.JPG
Views:	1
Size:	118.0 KB
ID:	1488299



    Finally, it would be nice if asdoc could:
    1. Export to docx, instead of doc
    2. Send graphs to the Word document. Internal command putdocx already does this, but if I am using asdoc, I don't expect to create a separate document with putdocx just for the charts...
    3. Support for UTF8. At the moment, any letters with accents get messed up, and text export gets confused by common text symbols such as ' and )
    Last edited by Pratap Pundir; 15 Mar 2019, 08:54.

    Leave a comment:

Working...
X