Statistical Analysis: Simulations

Model Simulation for Any Model, Built In or User Created

  • Average prediction with standard errors and confidence intervals
  • Prediction at the sample means
  • Analyze scenarios
  • Extrapolate to out of sample simulations
  • Fully accounts for all interactions and nonlinearities

Example

The following shows an ordered probit model for health satisfaction - the variable is coded 0-10. Some nonlinearity and two interaction terms are built into the model. The estimates are obtained for married individuals. The predicted probabilities for the 11 outcomes are simulated for the individuals in the sample. In a second simulation, the same predictions are computed for the unmarried individuals using the model estimated for married individuals. The third simulation examines the effect of age on the probability of the highest outcome. The simulation is listed then plotted with confidence limits for the simulation.

ORDERED ; If[married = 1] 
        ; Lhs = hsat
        ; Rhs = one,age,age*educ,female,female*educ,hhkids $

Normal exit:  23 iterations. Status=0, F=    43080.05

-----------------------------------------------------------------------------
Ordered Probability Model
Dependent variable                 HSAT
Log likelihood function    -43080.05498
Restricted log likelihood  -43815.85243
Chi squared [   5 d.f.]      1471.59489
Significance level               .00000
McFadden Pseudo R-squared      .0167930
Estimation based on N =  20730, K =  15
Inf.Cr.AIC  =  86190.1 AIC/N =    4.158
Underlying probabilities based on Normal
--------+--------------------------------------------------------------------
        |                  Standard            Prob.      95% Confidence
    HSAT|  Coefficient       Error       z    |z|>Z*         Interval
--------+--------------------------------------------------------------------
        |Index function for probability
Constant|    3.22007***      .04254    75.70  .0000     3.13670   3.30345
     AGE|    -.03177***      .00127   -25.06  .0000     -.03425   -.02928
AGE*EDUC|     .00091***   .8924D-04    10.24  .0000      .00074    .00109
  FEMALE|    -.12656*        .07517    -1.68  .0923     -.27389    .02077
        |Interaction FEMALE*EDUC
Intrct02|     .00769         .00666     1.15  .2484     -.00537    .02075
  HHKIDS|     .03937**       .01701     2.31  .0207      .00603    .07272
        |Threshold parameters for index
   Mu(1)|     .20742***      .01208    17.18  .0000      .18375    .23109
   Mu(2)|     .52526***      .01276    41.16  .0000      .50025    .55027
   Mu(3)|     .86479***      .01149    75.27  .0000      .84227    .88731
   Mu(4)|    1.13613***      .01049   108.29  .0000     1.11556   1.15669
   Mu(5)|    1.70965***      .00919   186.01  .0000     1.69163   1.72766
   Mu(6)|    1.98584***      .00887   223.76  .0000     1.96844   2.00323
   Mu(7)|    2.39664***      .00893   268.29  .0000     2.37913   2.41415
   Mu(8)|    3.05476***      .00985   310.22  .0000     3.03546   3.07406
   Mu(9)|    3.51443***      .01182   297.21  .0000     3.49125   3.53760
--------+--------------------------------------------------------------------
Note: nnnnn.D-xx or D+xx => multiply by 10 to -xx or +xx.
Note: ***, **, * ==>  Significance at 1%, 5%, 10% level.
-----------------------------------------------------------------------------

SIMULATE ; Scenario: @ Married = 1 ; Outcome = * $

---------------------------------------------------------------------
Model Simulation Analysis for Ordered Probit           Prob[Y = 10]
---------------------------------------------------------------------
Simulations are computed by average over sample observations
---------------------------------------------------------------------
User Function      Function   Standard
(Delta method)      Value      Error     |t|  95% Confidence Interval
---------------------------------------------------------------------
Subsample for this iteration is MARRIED  =  1   Observations:   20730
Avg.Prob(y= 0)      .01502     .00031   48.83      .01442      .01563
Avg.Prob(y= 1)      .00942     .00068   13.81      .00809      .01076
Avg.Prob(y= 2)      .02369     .00170   13.90      .02035      .02703
Avg.Prob(y= 3)      .04261     .00280   15.23      .03713      .04810
Avg.Prob(y= 4)      .05047     .00383   13.17      .04296      .05798
Avg.Prob(y= 5)      .15939     .00479   33.28      .15000      .16877
Avg.Prob(y= 6)      .09809     .00608   16.15      .08618      .11000
Avg.Prob(y= 7)      .15655     .00619   25.27      .14440      .16869
Avg.Prob(y= 8)      .22505     .00548   41.06      .21430      .23579
Avg.Prob(y= 9)      .10784     .00468   23.04      .09867      .11701
Avg.Prob(y=10)      .11188     .00239   46.85      .10720      .11656

SIMULATE ; Scenario: @ married = 0 ; Outcome = * $

---------------------------------------------------------------------
Model Simulation Analysis for Ordered Probit           Prob[Y = 10]
---------------------------------------------------------------------
Simulations are computed by average over sample observations
---------------------------------------------------------------------
User Function      Function   Standard
(Delta method)      Value      Error     |t|  95% Confidence Interval
---------------------------------------------------------------------
Subsample for this iteration is MARRIED  =  0   Observations:    6596
Avg.Prob(y= 0)      .01236     .00027   45.11      .01183      .01290
Avg.Prob(y= 1)      .00786     .00058   13.64      .00673      .00899
Avg.Prob(y= 2)      .02001     .00146   13.73      .01715      .02286
Avg.Prob(y= 3)      .03665     .00244   15.04      .03188      .04143
Avg.Prob(y= 4)      .04428     .00339   13.05      .03763      .05093
Avg.Prob(y= 5)      .14482     .00452   32.05      .13597      .15368
Avg.Prob(y= 6)      .09250     .00577   16.03      .08119      .10382
Avg.Prob(y= 7)      .15294     .00607   25.21      .14104      .16483
Avg.Prob(y= 8)      .23308     .00567   41.08      .22196      .24420
Avg.Prob(y= 9)      .11940     .00522   22.87      .10917      .12963
Avg.Prob(y=10)      .13610     .00354   38.41      .12915      .14304

SIMULATE ; Scenario: @ married = 0,1 & age = 25(5)65 ; Means ; Plot(ci) $

---------------------------------------------------------------------
Model Simulation Analysis for Ordered Probit           Prob[Y = 10]
---------------------------------------------------------------------
Simulations are computed at sample means of all variables
---------------------------------------------------------------------
User Function      Function   Standard
(Delta method)      Value      Error     |t|  95% Confidence Interval
---------------------------------------------------------------------
Subsample for this iteration is MARRIED  =  0   Observations:    6596
Func. at means      .12968     .01364    9.51      .10294      .15641
AGE     = 25.00     .25400     .01871   13.58      .21733      .29066
AGE     = 30.00     .20588     .01707   12.06      .17242      .23933
AGE     = 35.00     .16363     .01533   10.68      .13359      .19367
AGE     = 40.00     .12746     .01352    9.43      .10096      .15395
AGE     = 45.00     .09726     .01169    8.32      .07435      .12017
AGE     = 50.00     .07267     .00989    7.35      .05328      .09206
AGE     = 55.00     .05315     .00818    6.50      .03712      .06919
AGE     = 60.00     .03804     .00660    5.76      .02510      .05099
AGE     = 65.00     .02664     .00520    5.12      .01644      .03683
---------------------------------------------------------------------
Subsample for this iteration is MARRIED  =  1   Observations:   20730
Func. at means      .10122     .01223    8.28      .07725      .12519
AGE     = 25.00     .25878     .01898   13.63      .22158      .29599
AGE     = 30.00     .21014     .01744   12.05      .17596      .24432
AGE     = 35.00     .16733     .01576   10.62      .13644      .19821
AGE     = 40.00     .13059     .01397    9.35      .10320      .15797
AGE     = 45.00     .09984     .01214    8.23      .07605      .12363
AGE     = 50.00     .07475     .01031    7.25      .05454      .09496
AGE     = 55.00     .05478     .00856    6.40      .03801      .07155
AGE     = 60.00     .03929     .00693    5.67      .02571      .05287
AGE     = 65.00     .02757     .00547    5.04      .01685      .03828

graph