According to its help the .ado-program -fitstat- (source see below) should calculate McKelvey-Zavoina's R² for binary logit models. This worked fine until one of my latest updates of .ado-programs. Now, however, it will only calculate McKelvey-Zavoina's R² as a post-estimation command after -logit-, not anymore after -logistic-:
Is there anybody with a version of -fitstat- that will calculate McKelvey-Zavoina's R² after -logistic-? Which version is it and from where did you install it? Or is there anybody who can suggest a modification to the the current version (see below) of fitstat.ado to produce this statistic after -logistic-, as well? I had a look at the source code, but couldn't find the correct place for a respective modification.
The .ado-program -fitstat- is part of several different packages (and its versions) and it is not easy to find or update to the most recent one. Here I am referring to -fitstat- that is part of the package spost13_ado as it is available from "https://jslsoc.sitehost.iu.edu/stata" via
with version number
Code:
. sysuse auto, clear (1978 Automobile Data) . logit foreign price Iteration 0: log likelihood = -45.03321 Iteration 1: log likelihood = -44.947363 Iteration 2: log likelihood = -44.94724 Iteration 3: log likelihood = -44.94724 Logistic regression Number of obs = 74 LR chi2(1) = 0.17 Prob > chi2 = 0.6784 Log likelihood = -44.94724 Pseudo R2 = 0.0019 ------------------------------------------------------------------------------ foreign | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- price | .0000353 .0000844 0.42 0.676 -.0001301 .0002006 _cons | -1.079792 .5878344 -1.84 0.066 -2.231927 .0723419 ------------------------------------------------------------------------------ . fitstat | logit -------------------------+------------- Log-likelihood | Model | -44.947 Intercept-only | -45.033 -------------------------+------------- Chi-square | Deviance(df=72) | 89.894 LR(df=1) | 0.172 p-value | 0.678 -------------------------+------------- R2 | McFadden | 0.002 McFadden(adjusted) | -0.043 McKelvey & Zavoina | 0.003 Cox-Snell/ML | 0.002 Cragg-Uhler/Nagelkerke | 0.003 Efron | 0.002 Tjur's D | 0.002 Count | 0.703 Count(adjusted) | 0.000 -------------------------+------------- IC | AIC | 93.894 AIC divided by N | 1.269 BIC(df=2) | 98.503 -------------------------+------------- Variance of | e | 3.290 y-star | 3.301 . logistic foreign price Logistic regression Number of obs = 74 LR chi2(1) = 0.17 Prob > chi2 = 0.6784 Log likelihood = -44.94724 Pseudo R2 = 0.0019 ------------------------------------------------------------------------------ foreign | Odds Ratio Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- price | 1.000035 .0000844 0.42 0.676 .9998699 1.000201 _cons | .339666 .1996674 -1.84 0.066 .1073214 1.075023 ------------------------------------------------------------------------------ Note: _cons estimates baseline odds. . fitstat | logistic -------------------------+------------- Log-likelihood | Model | -44.947 Intercept-only | -45.033 -------------------------+------------- Chi-square | Deviance(df=72) | 89.894 LR(df=1) | 0.172 p-value | 0.678 -------------------------+------------- R2 | McFadden | 0.002 McFadden(adjusted) | -0.043 Cox-Snell/ML | 0.002 Cragg-Uhler/Nagelkerke | 0.003 Efron | 0.002 Tjur's D | 0.002 Count | 0.703 Count(adjusted) | 0.000 -------------------------+------------- IC | AIC | 93.894 AIC divided by N | 1.269 BIC(df=2) | 98.503
The .ado-program -fitstat- is part of several different packages (and its versions) and it is not easy to find or update to the most recent one. Here I am referring to -fitstat- that is part of the package spost13_ado as it is available from "https://jslsoc.sitehost.iu.edu/stata" via
Code:
net install spost13_ado, from(https://jslsoc.sitehost.iu.edu/stata)
Code:
*! 4.1.10 | 2017-01-05 | freese long | fixed bug in tobit (for v <14 and 15+)
Comment