如何用stata进行logit预测的命令怎么写

来源:学生作业帮助网 编辑:作业帮 时间:2024/05/04 05:37:37
如何用stata进行logit预测的命令怎么写

如何用stata进行logit预测的命令怎么写
如何用stata进行logit预测的命令怎么写

如何用stata进行logit预测的命令怎么写
predict [type] newvar [if] [in] [,statistic nooffset rules asif]
statistic description
------------------------------------------------------------------------
Main
pr probability of a positive outcome; the default
xb xb,fitted values
stdp standard error of the prediction
* dbeta Pregibon Delta-Beta influence statistic
* deviance deviance residual
* dx2 Hosmer and Lemeshow Delta chi-squared influence
statistic
* ddeviance Hosmer and Lemeshow Delta-D influence statistic
* hat Pregibon leverage
* number sequential number of the covariate pattern
* residuals Pearson residuals; adjusted for number sharing covariate
pattern
* rstandard standardized Pearson residuals; adjusted for number
sharing covariate pattern
score first derivative of the log likelihood with respect to
xb
------------------------------------------------------------------------
Unstarred statistics are available both in and out of sample; type
predict ...if e(sample) ...if wanted only for the estimation sample.
Starred statistics are calculated only for the estimation sample,even
when if e(sample) is not specified.
pr,xb,stdp,and score are the only options allowed with svy estimation
results.

􀁺 logit y x1 x2 x3
􀁺 mfx /*边际影响*/
􀁺 estat classification /*预测准确率表*/
􀁺 estat gof /*模型拟合优度检验*/
􀁺 lroc /*ROC曲线*/
􀁺 lsens /*敏感图*/