LOGISTIC回归及SAS程序(很全哦)

上传人:206****923 文档编号:37488579 上传时间:2018-04-17 格式:DOC 页数:13 大小:147.50KB
返回 下载 相关 举报
LOGISTIC回归及SAS程序(很全哦)_第1页
第1页 / 共13页
LOGISTIC回归及SAS程序(很全哦)_第2页
第2页 / 共13页
LOGISTIC回归及SAS程序(很全哦)_第3页
第3页 / 共13页
LOGISTIC回归及SAS程序(很全哦)_第4页
第4页 / 共13页
LOGISTIC回归及SAS程序(很全哦)_第5页
第5页 / 共13页
点击查看更多>>
资源描述

《LOGISTIC回归及SAS程序(很全哦)》由会员分享,可在线阅读,更多相关《LOGISTIC回归及SAS程序(很全哦)(13页珍藏版)》请在金锄头文库上搜索。

1、使用条件:使用条件: 应变量应变量 Y 是一个二值变量,取值为是一个二值变量,取值为 0 和和 1 自变量自变量 X1,X2,Xm。 P 表示在表示在 m 个自变量作用下事件发生的概率。个自变量作用下事件发生的概率。图像:图像:程序:程序: data ceshi; input x1-x18 y; cards; ; proc logistic des; model y=x1-x18/selection=stepwise; run;例:例:三种药物三种药物 drug 取值取值 0-2, 病情程度病情程度 degree 分重分重-轻两类(轻两类(0-1) ;因变量;因变量 response 为治疗效

2、果的效与无效为治疗效果的效与无效(1-0)Data ex12_1; Input drug degree response count; Datalines; 0 1 1 38 0 1 0 64 0 0 1 100 0 0 82 1 1 1 95 1 1 0 18 1 0 1 50 1 0 0 35 2 1 1 88 2 1 0 26 2 0 1 34 2 0 0 37 ; Proc logistic data=ex12_1 descending; Freq count; Class drug/param=ref descending; Model response=drug degree/rs

3、q scale=n aggregate; Run;Rsq 显示显示 R2Scale, SCALE= specifies method to correct overdispersion,指定参数,指定参数,=n 表示不表示不 需要修正。需要修正。 Aggregate 计算卡方检验统计量计算卡方检验统计量Class 语句将分类变量化成虚拟变量,三种药用两个虚拟变量表示。语句将分类变量化成虚拟变量,三种药用两个虚拟变量表示。The LOGISTIC Procedure Model Information Data Set WORK.EX12_1 Response Variable response

4、 Number of Response Levels 2 Frequency Variable count Model binary logit Optimization Technique Fishers scoringNumber of Observations Read 12 Number of Observations Used 12 Sum of Frequencies Read 577 Sum of Frequencies Used 577Response Profile Ordered Total Value response Frequency1 1 315 2 0 262Pr

5、obability modeled is response=1.Class Level Information Design Class Value Variables drug 2 1 0 1 0 1 0 0 0Model Convergence Status Convergence criterion (GCONV=1E-8) satisfied.Deviance and Pearson Goodness-of-Fit Statistics Criterion Value DF Value/DF Pr ChiSq Deviance 0.3749 2 0.1874 0.8291 Pearso

6、n 0.3689 2 0.1844 0.8316 模型拟合集优度检验,模型拟合集优度检验,Number of unique profiles: 6 Model Fit StatisticsInterceptIntercept and Criterion Only Covariates AIC 797.017 641.326 SC 801.375 658.757 -2 Log L 795.017 633.326R-Square 0.2444 Max-rescaled R-Square 0.3268The LOGISTIC Procedure Testing Global Null Hypothe

7、sis: BETA=0 Test Chi-Square DF Pr ChiSq Likelihood Ratio 161.6907 3 ChiSq drug 2 95.0859 ChiSq Intercept 1 -1.9594 0.2229 77.2441 ChiSqLikelihood Ratio 11.6428 2 0.0030Score 15.1091 2 0.0005Wald 13.0315 2 0.0015 模型检验模型检验 似然比检验(似然比检验(likelihood ratiotest) 、计分检验、计分检验(score test)、Wald 检验检验(Wald test)三种

8、三种Analysis of Maximum Likelihood Estimates Standard Wald Parameter DF Estimate Error Chi-Square Pr ChiSq Intercept 1 -5.5592 1.1197 24.6503 ChiSqLikelihood Ratio 12.7026 3 0.0053Score 10.4135 3 0.0154Wald 6.5331 3 0.0884Analysis of Maximum Likelihood EstimatesStandard Wald Parameter DF Estimate Error Chi-Square Pr ChiSqIntercept 1 3.6547 2.0911 3.0545 0.0805 X1 1 -0.0822 0.0521 2.4853 0.1149 X2 1 -0.00152 0.00187 0.6613 0.4161 X3 1 2.5016 1.1578 4.6689 0.0307The LOGISTIC ProcedureOdds Ratio EstimatesPoint 95% WaldEffect Estimate Confidence LimitsX1 0.921 0.832 1.020X2

展开阅读全文
相关资源
相关搜索

当前位置:首页 > 行业资料 > 其它行业文档

电脑版 |金锄头文库版权所有
经营许可证:蜀ICP备13022795号 | 川公网安备 51140202000112号