Announcement

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

  • classified after XT models - invalid subcommand classification

    Hello,
    I am using 4 binomial models. Logit, xtlogit re, xtlogit pa, and xtlogit fe. After logit I use “estat classification” normally. After RE, FE, and PA I am trying use “estat classification” but show this error: “invalid subcommand classification”.
    Can someone help me about how can I make classified after XT models?
    Thanks
    Erasmo

    Code:
    . logit DUMMYRET LNVM, vce (cluster id) nolog
    
    Logistic regression                               Number of obs   =      21236
                                                      Wald chi2(1)    =      70.28
                                                      Prob > chi2     =     0.0000
    Log pseudolikelihood = -14632.346                 Pseudo R2       =     0.0032
    
                                       (Std. Err. adjusted for 619 clusters in id)
    ------------------------------------------------------------------------------
                 |               Robust
        DUMMYRET |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
    -------------+----------------------------------------------------------------
            LNVM |   .0578859   .0069048     8.38   0.000     .0443527    .0714191
           _cons |  -.6494957   .0960829    -6.76   0.000    -.8378146   -.4611768
    ------------------------------------------------------------------------------
    
    . estat classification
    
    Logistic model for DUMMYRET
    
                  -------- True --------
    Classified |         D            ~D  |      Total
    -----------+--------------------------+-----------
         +     |      9488          7898  |      17386
         -     |      1779          2071  |       3850
    -----------+--------------------------+-----------
       Total   |     11267          9969  |      21236
    
    Classified + if predicted Pr(D) >= .5
    True D defined as DUMMYRET != 0
    --------------------------------------------------
    Sensitivity                     Pr( +| D)   84.21%
    Specificity                     Pr( -|~D)   20.77%
    Positive predictive value       Pr( D| +)   54.57%
    Negative predictive value       Pr(~D| -)   53.79%
    --------------------------------------------------
    False + rate for true ~D        Pr( +|~D)   79.23%
    False - rate for true D         Pr( -| D)   15.79%
    False + rate for classified +   Pr(~D| +)   45.43%
    False - rate for classified -   Pr( D| -)   46.21%
    --------------------------------------------------
    Correctly classified                        54.43%
    --------------------------------------------------
    
    . xtlogit DUMMYRET LNVM, re vce (cluster id) nolog
    
    Calculating robust standard errors:
    
    Random-effects logistic regression              Number of obs      =     21236
    Group variable: id                              Number of groups   =       619
    
    Random effects u_i ~ Gaussian                   Obs per group: min =         1
                                                                   avg =      34.3
                                                                   max =        95
    
    Integration method: mvaghermite                 Integration points =        12
    
                                                    Wald chi2(1)       =     21.88
    Log pseudolikelihood  = -14607.845              Prob > chi2        =    0.0000
    
                                       (Std. Err. adjusted for 619 clusters in id)
    ------------------------------------------------------------------------------
                 |               Robust
        DUMMYRET |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
    -------------+----------------------------------------------------------------
            LNVM |   .0377137   .0077938     4.84   0.000     .0224381    .0529892
           _cons |  -.3800981   .1068064    -3.56   0.000    -.5894348   -.1707615
    -------------+----------------------------------------------------------------
        /lnsig2u |  -2.946617   .2009394                     -3.340451   -2.552783
    -------------+----------------------------------------------------------------
         sigma_u |   .2291661   .0230242                      .1882047    .2790425
             rho |   .0157125   .0031076                       .010652    .0231208
    ------------------------------------------------------------------------------
    
    . estat classification
    invalid subcommand classification
    r(321);
    Last edited by Erasmo Silva; 11 May 2019, 11:52.
Working...
X