Announcement

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

  • outreg2 help requested

    Why does one outreg2 command work and the other does not, when they are the same except for one variable?

    This one works well:
    logit AssuredOrNot Words BoilerWords Fog HardInfoMix1000 RedundantWords Specificity1000 Polarity1000 Subjectivity1000 LnTotalAssets roa lev GovSysAtt Indpres FX_INC SP_ESG_SCORE INSTOWN_PERCENT ESI ib0.NumIndsector Fiscalyear, vce(cluster CompName) baselevels
    outreg2 using "C:\Users\raosunit\Documents\EVA and Sustainability\Stata files\JBE\Assured & AuditFirm_wControlsv3.xls", addstat("Wald chi2", e(chi2), " Prob > chi2", e(p), "No. of Companies", e(N_clust), "Pseudo R2", e(r2_p), "Deg Freedom-Model", e(df_m) ) replace ctitle(AssuredOrNot) label

    outreg2 using "C:\Users\raosunit\Documents\EVA and Sustainability\Stata files\JBE\Assured & AuditFirm_wControlsv3.xls", addstat("Wald chi2", e(chi2), " Prob > chi2", e(p), "No. of Companies", e(N_clust), "Pseudo R2", e(r2_p), "Deg Freedom-Model", e(df_m) ) replace ctitle(AssuredOrNot) label


    This one does not - Stata tells me that that this is invalid syntax:
    logit AssuredOrNot Words BoilerWords Fog HardInfoMix1000 RedundantWords Specificity1000 Polarity1000 Subjectivity1000 LnTotalAssets roa lev GovSysAtt Indpres2 FX_INC SP_ESG_SCORE INSTOWN_PERCENT ESI ib0.NumIndsector Fiscalyear, vce(cluster CompName) baselevels

    outreg2 using "C:\Users\raosunit\Documents\EVA and Sustainability\Stata files\JBE\Assured & AuditFirm_wControlsv5.xls", addstat("Wald chi2", e(chi2), "Prob > chi2", e(p), "No. of Companies", e(N_clust), "Pseudo R2", e(r2_p), "Deg Freedom-Model", e(df_m) ) replace ctitle(AssuredOrNot) label


    Indpres and Indpres2 are variables indicating Industry Pressure, but calculated using different methods.




    Also, the output for the 2nd logit does not give Wald chi2 & Prob>chi2 as I have pasted below. Is that why outreg2 is not working for the 2nd logit?

    I would be very grateful for some guidance.

    logit AssuredOrNot Words BoilerWords Fog HardInfoMix1000 RedundantWords Specificity1000 Polarity1000 Subj
    > ectivity1000 LnTotalAssets roa lev GovSysAtt Indpres2 FX_INC SP_ESG_SCORE INSTOWN_PERCENT ESI ib0.NumInds
    > ector Fiscalyear, vce(cluster CompName) baselevels

    note: 0.NumIndsector != 0 predicts failure perfectly;
    0.NumIndsector omitted and 37 obs not used.

    note: 9.NumIndsector omitted because of collinearity.
    Iteration 0: log pseudolikelihood = -589.832
    Iteration 1: log pseudolikelihood = -32.526602
    Iteration 2: log pseudolikelihood = -28.981431
    Iteration 3: log pseudolikelihood = -16.575668
    Iteration 4: log pseudolikelihood = -14.323127
    Iteration 5: log pseudolikelihood = -13.593377
    Iteration 6: log pseudolikelihood = -13.49977
    Iteration 7: log pseudolikelihood = -13.48277
    Iteration 8: log pseudolikelihood = -13.479702
    Iteration 9: log pseudolikelihood = -13.479324 (not concave)
    Iteration 10: log pseudolikelihood = -13.479306
    Iteration 11: log pseudolikelihood = -13.479296 (not concave)
    Iteration 12: log pseudolikelihood = -13.479294
    Iteration 13: log pseudolikelihood = -13.479294

    Logistic regression Number of obs = 1,171
    Wald chi2(18) = .
    Prob > chi2 = .

    Log pseudolikelihood = -13.479294 Pseudo R2 = 0.9771

    (Std. err. adjusted for 186 clusters in CompName)

    Robust
    AssuredOrNot Coefficient std. err. z P>z [95% conf. interval]

    Words -.0000162 .0000264 -0.61 0.539 -.0000679 .0000355
    BoilerWords 2.588939 13.69191 0.19 0.850 -24.24672 29.4246
    Fog .7520213 .4479711 1.68 0.093 -.1259859 1.630028
    HardInfoMix1000 .1150372 .0332754 3.46 0.001 .0498187 .1802557
    RedundantWords 34.78673 43.50393 0.80 0.424 -50.4794 120.0529
    Specificity1000 -.1367624 .0634322 -2.16 0.031 -.2610873 -.0124376
    Polarity1000 .0265486 .0264736 1.00 0.316 -.0253386 .0784359
    Subjectivity1000 .0342314 .0561648 0.61 0.542 -.0758495 .1443124
    LnTotalAssets .8874881 1.152679 0.77 0.441 -1.371721 3.146697
    roa 13.48434 8.483382 1.59 0.112 -3.142786 30.11146
    lev .0589169 6.565389 0.01 0.993 -12.80901 12.92684
    GovSysAtt 2.740119 2.215303 1.24 0.216 -1.601796 7.082033
    Indpres2 -56.98134 36.19825 -1.57 0.115 -127.9286 13.96593
    FX_INC 5.47e-06 . . . . .
    SP_ESG_SCORE .068302 .0364258 1.88 0.061 -.0030912 .1396953
    INSTOWN_PERCENT -.2443227 .1565149 -1.56 0.119 -.5510862 .0624408
    ESI -.0720404 1.538307 -0.05 0.963 -3.087066 2.942985

    NumIndsector
    Communication Services 0 (empty)
    Consumer Discretionary 1916.888 . . . . .
    Energy 1292.717 778.974 1.66 0.097 -234.0436 2819.478
    Industrials 2203.504 1590.718 1.39 0.166 -914.2456 5321.253
    Health Care 1079.851 603.6592 1.79 0.074 -103.2993 2263.001
    Information Technology 1006.94 762.6687 1.32 0.187 -487.8631 2501.743
    Financials 1572.106 551.7738 2.85 0.004 490.6489 2653.563
    Materials 1231.481 . . . . .
    Consumer Staples 1196.663 588.4617 2.03 0.042 43.29937 2350.027
    Utilities 0 (omitted)

    Fiscalyear -.9087247 .2366973 -3.84 0.000 -1.372643 -.4448066
    _cons 1960.058 488.021 4.02 0.000 1003.554 2916.561

    Note: 618 failures and 230 successes completely determined.


  • #2
    Please read FAQ sections 10 and 12 on how to ask a question.

    Comment


    • #3
      I am so sorry my question is not clear. I would be very grateful for some guidance.

      I used the outreg2 command with the same variables. However, the first one worked and the second did not. Stata gave me the following message for the second one: invalid syntax

      The logit output for the second one is also unusual, as there is no Wald chi2.

      I did try to use dataex. Stata is giving me the following message:

      input statement exceeds linesize limit. Try specifying fewer variables
      r(1000);

      Here are fewer variables:

      Code:
      * Example generated by -dataex-. For more info, type help dataex
      clear
      input byte AssuredOrNot long Words double(BoilerWords Fog) float HardInfoMix1000 double RedundantWords float(Specificity1000 Polarity1000 Subjectivity1000) double LnTotalAssets float(roa lev) byte(GovSysAtt Indpres Indpres2) long FX_INC
      1 32864 .131663827 16.13  55.71446 .009987309 113.25462  115.1161  364.3562  10.21280880009139   .11717431   .18704587 1 3 41 0
      0 33159 .128170331 16.02  48.82536 .008506258 106.69803 118.22666  370.8522 10.314139187331593   .13546227   .13871203 1 1 42 0
      1 34280 .145770128 18.08  53.93816 .010190348  93.20303  95.49712  353.1811 10.361418600547594   .13546938   .14182693 1 3 41 0
      1 41765 .130899078 17.32 71.136116 .015889575 101.20914   95.1646  357.2802  10.43046207804149   .13118432   .14511749 0 3 41 0
      1 53493  .12908231 17.29   83.3567 .008142477  98.79797  107.8888   371.834 10.420792142399828   .13886736   .12915052 1 3 41 0
      1 61123 .173666214 17.33   54.7748 .055799321  85.71242  99.32914  363.6644 10.348461793739006   .15880035     .214938 1 3 41 0
      1 75411 .138573948 14.93  85.84954 .037375896  98.03609 104.90715   371.109 10.400711085883833   .14697564   .26621658 1 3 41 0
      1 60592 .110823211 18.01  79.66398 .014625229  99.53459 107.62388  390.3213 10.401410290946595   .15346745    .3245001 1 6 41 0
      1 71447 .130628298 18.48 71.115654  .01582151  96.22517 112.89426   397.495  10.54499927491401   .12788585    .3185827 1 6 41 0
      0  9774 .186719869 17.18 37.957848 .005469009 102.10764 158.75104  363.3116 11.888838170816369  .032863658   .17932186 0 0  0 0
      0 14513 .094811548 18.02  24.32302 .030556485  59.94625 129.17941  323.5196 12.526865457047755   .04335665   .20771357 0 0  0 0
      0 27204 .123511248 16.53  45.03014 .012111573  77.59888 149.35635  389.1337 12.488409206157188  -.00989651    .2294935 1 0  0 0
      0 22625 .183558011 15.22  63.20442 .028833943  89.54696 159.63387  385.5539 12.499905761466461   .04523838   .24121173 1 0  0 0
      0 12608 .096922589  14.5  46.24048  .01067517  87.64277  159.3748   449.039 12.503919134827973   .07373669    .2214105 1 0  0 0
      0 44596 .118575657 15.53  54.69101 .112807803  86.17365 142.03189  407.0662 12.507812936532986  .014583534   .22969805 1 0  0 0
      0 52230 .125119663 15.17  61.21003 .081583724  93.50948  125.8874  375.7926 12.514714763446529   .02667499   .24614877 1 0  0 0
      0 11468 .195674922 15.62   62.3474 .067246046   93.3031  97.85973 381.88815 12.905877613754186  .033141118    .3029289 1 0  0 0
      0 10935  .22432556 15.47  51.66895 .039066077  88.06584  107.5912  375.9054 12.908726989452148   .03213305   .29112405 1 0  0 0
      0 13836 .146574154 14.67 71.480194 .035881831  94.68054 120.32446 380.91675  13.00379828602207   .06631434    .2866333 1 0  0 0
      0  1735 .128530259  15.7  81.84438          0  95.10087 149.55989 352.90765 10.281855492759926   .14137955    .4894856 0 0 22 0
      0  8698 .127730513 16.55  60.12877 .006647865  76.79926   164.643  416.6987 11.167416520015664    .0750007    .4372757 1 4 22 0
      0 19440 .100617284 14.17  82.51028 .004193702 113.16872  120.1786  350.2948  10.27990836235622   .11571468   .15687424 1 2 22 0
      0 13522 .147759207 15.31  57.53587 .009009009  92.81171  129.6979  346.3584  10.49621123252083   .04745279   .19375396 1 2 22 0
      0 12692 .096359912 14.05   72.4866 .001777101   98.0145 151.04662  396.5597 10.589457135662315    .0908073   .23890334 1 1 22 0
      0 17054  .11791955 15.29 65.908295 .007728596  90.53594 133.28528  363.4167 10.655356463208998   .11505918   .20540996 1 1 22 0
      1 17277 .115702958  16.5   60.6008 .001484368  78.13857 139.76689  398.8433 10.870121965057393   .10927464    .2184089 1 0 22 0
      1 53351 .135198965  16.5  73.34445 .025408348  88.93929 129.42139 374.47015 11.011618593792388   .07637242    .2073422 1 1 21 0
      0 68158 .132368908 17.16  81.73655 .024535493  93.29793 123.04269  381.7793  11.00670410861179   .07843802    .1997419 1 0 22 0
      1 61195 .123408775 16.29  88.58567 .017196231 101.51156 109.23254  373.7192 11.115949224257971   .08868892   .26898193 1 0 21 0
      0 31379 .137767297 16.83  44.32901 .027771945  81.93378 137.19604  377.5587 10.626363423818374   .05542748   .08234038 1 3 22 0
      0 48225 .096526698 14.44  176.1949 .078559867 135.90462  120.6387  389.1781 10.627333661845343   .10723204   .14233762 0 4 22 0
      0 41789 .098710187 17.05  99.47594  .01534689  106.1284 135.02625  390.3607  10.87172536503303  .026582615    .3926822 1 2 22 0
      0 63119 .111471981 17.42  79.61153 .023114191   99.1619 129.04776  382.7028 11.241772694469658  .006255738    .3568525 1 4 22 0
      0  2597 .275702734 29.29 118.59838 .013262599 140.93184  86.60201  362.1169  9.584353064755348   .11653864   .12950857 0 3 21 0
      0  5652 .127742392 14.75  40.69356 .004269294  94.83369  186.5318  426.8192 11.094451102268424   .02483094  .022141175 0 1 31 0
      0  8449 .104272695 16.22  60.59889 .016583108 114.56977  149.2879  348.7336 11.663386489239402   .01666423   .02523293 1 2 31 0
      0 10469 .077084726  15.3   39.4498 .008278425  94.27834 137.39215   383.682 11.706079801428672   .02603312   .03764828 1 4 31 0
      0 12561  .09099594 12.08  43.94555 .001211143  98.95709 141.80804   419.072 11.693303467619163   .02463951    .0404452 1 3 31 0
      0 10838   .1226241 15.08  40.32109 .006233442 107.39989 148.79546  370.9709 11.680607045024669   .02141963   .04020092 1 4 31 0
      0 17518 .092076721 15.55 37.275944 .001880443 111.65659 135.43033  361.8142 11.773896451584443  .020482363  .036127225 1 6 31 0
      0 23072 .082350902 15.65 37.881416 .008091078 105.84258 142.36893 355.77145  11.82931889330366  .033552695   .03854479 1 4 31 0
      0  9152 .208806818 16.63  74.51923 .030099728  89.05157 104.05219  330.5863   8.81744592104187   .04843727           0 0 2 22 0
      0 15956 .147154675 16.85  92.50439  .02769331 112.81023  81.07549  356.4291     8.905037290767    .4487719   .20355543 0 2 22 0
      0 11802 .152092866 17.23   67.4462  .01783591   84.7314  112.2661  334.8631  8.929832503272403   .08445857   .27627748 0 1 22 0
      0 19310 .126929052 17.23  80.58001 .026813029       100  85.85147  345.1518  8.854664928370534    .0989011    .3032682 0 1 22 0
      0  5675 .118590308 17.65  81.76212 .002942138 103.78854 117.78152  338.0808   8.93748122841604 -.004072517    .3815029 0 0 22 0
      0  9457  .11536428 16.46  84.17046 .008426966  98.02263 128.04678  338.7142  9.179468708309095  .070544556   .22586633 1 2 22 0
      0 18317 .274662881 17.88  65.34913   .0915251  84.18409  94.12013 359.35065  9.111293218374948   .11173678   .21331567 1 0 22 0
      0 21283 .276276841 17.22  75.50627 .083299472  79.59404  87.25705 355.44455  9.276689752517717  .068688005   .25257346 1 0 22 0
      0 22604 .266236064 17.74  71.04937  .07924039  84.67528  91.21612  364.7207   9.28868933838716   .05076283    .1537679 1 3 22 0
      0 27047 .231375014 17.42   64.4064 .067553993  78.93667 102.06303  372.4863  8.919854372191667   .05361679   .22128627 1 4 22 0
      0 24912 .232458253 18.79   44.5167 .058288876  68.56133 103.00854  373.0831  8.961109485898655   .05927636    .2442905 0 2 22 0
      1 29961 .251460232 19.63  45.32559 .065046384  63.64941  94.88049   384.974  9.039077442538963    .0811773    .2137432 1 3 21 0
      0  9699 .191050624 16.64  42.78791  .00623733  79.38963 149.80983  394.8734  9.250406881189265  .068374835    .1966317 1 1 25 0
      0 11070 .095483288 18.01  38.48238  .00015108  78.95213 159.92767  389.0128   9.32194435655585   .06470078    .2039407 1 0 25 0
      0 15806 .117803366 18.27  33.34177 .002721226  76.17361 133.08182  388.6854  9.446163200447465   .08180418   .23497768 0 2 25 0
      0 12741  .17157209 19.42  46.69963 .001481988  85.23664  97.73088  364.8012  9.439171717080004   .07236324   .27963695 0 1 25 0
      0 25084 .203755382 20.37  74.39005 .008594158  89.97768  80.85196  315.2563    9.4749405963596   .04845308   .28493142 1 1 25 0
      0 26720 .176122754 20.36  80.38922 .009233151  95.65868  79.17321  312.4092  9.510881905990688   .07619633   .27053362 1 1 25 0
      0 28390 .142972878 17.65  76.85805  .02912451  87.17858  88.49937  353.9661  9.567364255028581    .0856641   .27461216 1 1 25 0
      0 25920 .096334877 15.66  81.79012 .013075571  81.01852 127.24336  384.7946  9.737539219940114   .06890059    .2711459 1 2 25 0
      0 24769 .135532319 15.97  96.49158 .048361283  92.05054  90.97277  363.5562  9.789764389432989   .05569717   .28360626 0 2 25 0
      0 25146 .130955222 15.47 102.08383 .035227195  92.26119  93.20681  358.5586  9.785778889114061   .05577898   .27137482 1 3 25 0
      0 32558 .159100682 16.96  74.29818 .038535267  83.38964 114.01533  386.9077    9.7604540143227   .07372004    .2278635 0 4 25 0
      0 31272  .15911998 16.88 69.583015 .050298469  80.83909 118.69742 384.67725  9.799714664818735   .03500549    .2175654 0 4 25 0
      0 37705 .108765416 17.28  49.62207 .009286054 76.170265 133.28754   392.116   9.86153471051546   .07809868    .1748226 1 0 25 0
      0 11530 .110667823 18.97  43.88552 .031027535 110.14744  123.0222  408.8098  6.168670960500123   .06941458    .2957213 0 1 22 .
      0  9032  .07119132 18.12  44.06554 .009183673 110.49602 115.71777  403.8013  6.667466840449646    .3753378  .012611886 0 0 22 .
      0  5257 .081415256 20.37  76.65969  .00187316  128.9709 109.49413  389.0509  6.919720410443886   .09587594 .0036737786 0 2 22 .
      0  5549  .09515228 21.37  68.66102 .002517623  128.3114 105.19797  427.0944  7.240471183699749   .12569627           0 0 0 22 .
      0  5834 .199520055 19.74  81.59068 .005059022 141.75523 117.02656  409.2553 7.8684685556089855   .09749996   .03864461 0 1 22 .
      0  4558 .127468188 20.52  89.29355   .0028454 129.88153  91.12318   406.601  8.107025845094178    .0762261   .01959191 0 0 22 .
      0  5647 .270054896  20.6   59.6777 .012373737 137.59518  92.11044  372.3372  8.343306838051346   .15635553 .0022608486 0 3 22 .
      0  8798 .059104342 15.18  227.8927 .002464876  162.4233 140.50491  397.5524 11.958072718217098  .011308883   .02711569 0 0 31 0
      0 16782 .057919199 16.13 144.97676 .026122061 136.69408 114.46104   354.429 11.967523535628603   .03169072   .02951369 0 0 31 0
      0 27472 .140870705 10.72  172.2117 .013307393 148.91525    129.97  361.5267 11.795484436723239  .006437898   .04423605 0 2 31 0
      0 32597 .168880572 16.36   48.7775 .043708814  75.19097 126.92361  369.2714 11.737611825541952  .006286294   .04683968 0 2 31 0
      0 34718 .146206579 15.92  53.02725  .01197076  80.64981  124.4887  383.8118 11.751524955502674  .018165061    .0453969 0 2 31 0
      0 33934  .10434962 16.46  44.26239 .004309313   76.7372 150.90483  393.0992 11.724158365258603  .018458549   .04215512 0 4 31 0
      0 32529 .109748225 15.98   53.9826  .00743336  82.17283 143.98138 376.22205 11.594311884842648  .026272366   .04738244 0 3 31 0
      0 99970  .11856557 17.68 30.319096 .203584945  65.02951 170.47957  371.7955 11.558434060200995   .02074415    .0489604 0 4 31 0
      0 30270 .251007598 16.84  41.79055 .026787105  69.44169 169.74677  391.0312 11.595518763274082  .017282018   .05843845 1 6 31 0
      0 32858 .131931341 16.46  78.24579 .009942304  93.21931  150.3782  381.2606 11.630014926826567   .03161303   .05648361 0 4 31 0
      0 40399 .077699943 14.66   59.6797 .012725299  93.91322 119.51298   350.738 10.459066632489291   .13009553    .4013884 1 2 24 0
      1 14250 .081473684 13.94  78.24561 .015548069  89.96491 106.36096  348.3192 10.447989702661502   .14706309    .3971864 0 3 23 0
      1 21647 .225204416 16.57  47.39687 .035709184  73.86705  125.1988  380.4812 10.356440389711647    .1665978   .40824565 0 1 23 0
      1 23938 .231305874 16.76  48.79271 .029544575  75.73732  126.0191  381.9594  10.73491732089608    .3100017    .3022076 0 4 23 0
      1 28269 .168877569 15.68 105.69882 .041863765 109.76688 127.40205  372.8794 10.673642069456857    .2366094    .3016064 0 3 23 0
      0 10302 .113764318 16.63  56.97923 .001815182  87.07047 140.21062  339.9192 10.674174310551491   .06667438    .3711509 0 4 42 0
      0 16518 .084634944 15.96  65.14106 .004699038  89.72031 160.28415  358.3037 10.787564962045632    .1571827    .3786017 0 4 42 0
      0 11681 .133807037 16.18 122.67786 .005343625 128.41367  131.9378  349.8129 10.844939080068784   .05039591   .43860435 0 7 42 0
      0 17186 .151053183 16.87 103.68905 .022172079  114.5118 135.76668  332.8486 10.873982338423795  .024287203    .4133371 0 7 42 0
      0 24108 .080637133   9.3  45.54505 .000376166  77.69205  127.4433  387.3949  10.54499927491401  .026377445    .3232685 0 0  3 .
      0 34530 .092122792 10.52  43.58529 .000278487  79.75674  126.0616  412.8968 10.604578100850384    .0270096    .3522409 0 0  3 .
      0 39549 .087208273 10.74  55.24792 .002530745  84.85676 125.61502 405.20535   10.7178562946849    .0305614   .34405935 0 0  3 .
      0 30819 .091469548 11.24  71.38454          0  89.42535 116.11212  404.9561 10.786180134979347  .028067345    .3259494 0 1  3 .
      0 36143 .093434413 11.11  71.77047  .00205799  92.52137 112.67275   415.204 10.828837128898629  .024001585   .30730355 0 1  3 .
      0 35137 .099467797 14.41  76.18749 .000862108  94.48729 105.92185   410.925 10.863278289856135   .03716753    .2888191 1 1  3 .
      0 66985 .079346122 14.64   95.1407 .018534909 100.50011  94.02232  394.4659 10.903512631130047   .02315743   .28668126 0 0  3 .
      0 81396 .073824267 14.74  88.49329 .024278445  98.50607  99.52076  387.4428 10.940472633633293  .026243486   .29829475 1 0  3 .
      end
      label values AssuredOrNot AssuredOrNot
      label def AssuredOrNot 0 "Not Assured", modify
      label def AssuredOrNot 1 "Assured", modify
      Here is dataex for the variables SP_ESG_SCORE INSTOWN_PERCENT ESI NumIndsector Fiscalyear in 1/100

      Code:
      * Example generated by -dataex-. For more info, type help dataex
      clear
      input byte SP_ESG_SCORE float(INSTOWN_PERCENT ESI) byte NumIndsector int Fiscalyear
      66 25.37 1 3 2009
      66 25.37 1 3 2010
      66 25.37 1 3 2011
      66 25.37 1 3 2012
      66 25.37 1 3 2013
      66 25.37 1 3 2014
      66 25.37 1 3 2015
      66 25.37 1 3 2016
      66 25.37 1 3 2017
      74 24.04 0 0 2005
      74 24.04 0 0 2007
      74 24.04 0 0 2008
      74 24.04 0 0 2009
      74 24.04 0 0 2010
      74 24.04 0 0 2011
      74 24.04 0 0 2012
      74 24.04 0 0 2015
      74 24.04 0 0 2016
      74 24.04 0 0 2017
      82 23.93 1 4 2013
      82 23.93 1 4 2017
      84 30.06 0 4 2005
      84 30.06 0 4 2006
      84 30.06 0 4 2007
      84 30.06 0 4 2008
      84 30.06 0 4 2009
      84 30.06 0 4 2010
      84 30.06 0 4 2011
      84 30.06 0 4 2012
      84 30.06 0 4 2014
      84 30.06 0 4 2015
      84 30.06 0 4 2016
      84 30.06 0 4 2017
      68  27.1 0 5 2017
      54 31.11 0 6 2007
      54 31.11 0 6 2011
      54 31.11 0 6 2013
      54 31.11 0 6 2014
      54 31.11 0 6 2015
      54 31.11 0 6 2016
      54 31.11 0 6 2017
      55 32.84 0 4 2005
      55 32.84 0 4 2006
      55 32.84 0 4 2007
      55 32.84 0 4 2008
      55 32.84 0 4 2009
      55 32.84 0 4 2010
      55 32.84 0 4 2011
      55 32.84 0 4 2013
      55 32.84 0 4 2014
      55 32.84 0 4 2015
      55 32.84 0 4 2016
      55 32.84 0 4 2017
      72 30.56 1 7 2005
      72 30.56 1 7 2006
      72 30.56 1 7 2007
      72 30.56 1 7 2008
      72 30.56 1 7 2009
      72 30.56 1 7 2010
      72 30.56 1 7 2011
      72 30.56 1 7 2012
      72 30.56 1 7 2013
      72 30.56 1 7 2014
      72 30.56 1 7 2015
      72 30.56 1 7 2016
      72 30.56 1 7 2018
       .     . 1 4 2008
       .     . 1 4 2009
       .     . 1 4 2010
       .     . 1 4 2011
       .     . 1 4 2012
       .     . 1 4 2013
       .     . 1 4 2014
      53 26.42 0 6 2005
      53 26.42 0 6 2006
      53 26.42 0 6 2009
      53 26.42 0 6 2011
      53 26.42 0 6 2012
      53 26.42 0 6 2013
      53 26.42 0 6 2014
      53 26.42 0 6 2015
      53 26.42 0 6 2016
      53 26.42 0 6 2017
      36 29.52 0 8 2013
      36 29.52 0 8 2014
      36 29.52 0 8 2015
      36 29.52 0 8 2016
      36 29.52 0 8 2017
      54  28.4 0 3 2014
      54  28.4 0 3 2015
      54  28.4 0 3 2016
      54  28.4 0 3 2017
       .     . 1 9 2006
       .     . 1 9 2007
       .     . 1 9 2008
       .     . 1 9 2009
       .     . 1 9 2010
       .     . 1 9 2011
       .     . 1 9 2012
       .     . 1 9 2013
      end
      label values NumIndsector Indsectorlabel
      label def Indsectorlabel 0 "Communication Services", modify
      label def Indsectorlabel 3 "Industrials", modify
      label def Indsectorlabel 4 "Health Care", modify
      label def Indsectorlabel 5 "Information Technology", modify
      label def Indsectorlabel 6 "Financials", modify
      label def Indsectorlabel 7 "Materials", modify
      label def Indsectorlabel 8 "Consumer Staples", modify
      label def Indsectorlabel 9 "Utilities", modify


      Comment


      • #4
        You are in a bind here, as you can't give us a way even of reproducing your error.

        outreg2 is from SSC (as you are asked to explain: FAQ Advice #12) but the program author left Statalist long ago. Also, it's quite a popular command judging from download data but many experienced users don't use it all (I don't) and questions on it here are often unanswered.

        So what to do? My only suggestions are to tell us more about the variables in question

        Code:
        summarize indpres* 
        
        tab indpres indpres2
        and to

        Code:
        set trace on 
        and see where the code fails. For example, it might tell you whether outreg2 is rejecting your code early on or deep inside the program.

        Comment


        • #5
          Dr. Cox,

          Thank you so much for your response. I appreciate your efforts so much!

          I set trace on and I am unable to tell whether the rejection is early or deep in the program. I am attaching the log file and I would be extremely grateful for some guidance.

          Here are the results of the the sum & tab commands:

          sum Indpres Indpres2

          Variable | Obs Mean Std. dev. Min Max
          -------------+---------------------------------------------------------
          Indpres | 1,233 2.169505 1.738966 0 7
          Indpres2 | 1,233 25.58394 11.25658 0 42


          tab Indpres Indpres2

          | Indpres2
          Indpres | 0 2 3 20 21 22 23 24 25 26 30 31 36 37 41 42 | Total
          -----------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+----------
          0 | 38 3 88 3 24 37 3 27 6 0 2 12 3 1 4 6 | 257
          1 | 0 0 23 12 23 22 8 29 42 10 8 10 8 9 0 33 | 237
          2 | 0 0 0 6 67 32 0 34 20 40 3 48 3 17 0 0 | 270
          3 | 0 0 0 0 39 15 8 8 2 13 12 18 8 3 24 0 | 150
          4 | 0 0 0 0 0 33 5 20 6 0 0 54 15 13 0 81 | 227
          5 | 0 0 0 0 0 0 0 9 0 0 6 0 0 22 0 0 | 37
          6 | 0 0 0 0 0 0 0 0 0 0 0 16 0 0 14 0 | 30
          7 | 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 25 | 25
          -----------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+----------
          Total | 38 3 111 21 153 139 24 127 76 63 31 158 37 65 42 145 | 1,233


          Attached Files

          Comment


          • #6
            Thanks for the output. The error is quite deep inside outreg2 and so far as I can tell arises because that command is not coping adequately with the statistical results from your model fit. Whether that is diagnostic of a poor or problematic model fit and/or a bug or misfeature in outreg2 I really can't tell.

            If you don't get a better answer an option is to email the program author, but naturally I can't speak on his behalf.

            Comment


            • #7
              Dr. Cox,

              Do you use putexcel to export your logit and regression results? How about the results of the sum, tab and pwcorr?

              I will write to to Roy Wada, as you suggest.

              Comment

              Working...
              X