Sas “如何清除”;“结果”;从Proc单变量到仅显示特定表
我一直在使用单变量过程,以便从一系列分布(对数正态分布、指数分布、伽马分布)中获得p值,并得出以下问题: 我使用以下代码获得每个分布的拟合优度测试的p值:Sas “如何清除”;“结果”;从Proc单变量到仅显示特定表,sas,statistics,distribution,resultset,proc,Sas,Statistics,Distribution,Resultset,Proc,我一直在使用单变量过程,以便从一系列分布(对数正态分布、指数分布、伽马分布)中获得p值,并得出以下问题: 我使用以下代码获得每个分布的拟合优度测试的p值: ods select all/*ParameterEstimates GoodnessOfFit*/; proc univariate data=results.Parametros_Prueba_1; var Monto_1.; histogram / lognormal (l=1 color=red
ods select all/*ParameterEstimates GoodnessOfFit*/;
proc univariate data=results.Parametros_Prueba_1;
var Monto_1.;
histogram /
lognormal (l=1 color=red SHAPE=&ParamLOGN2_1 SCALE=&ParamLOGN1_1)
gamma (l=1 color=red SHAPE=&ParamGAM1_1 SCALE=&ParamGAM2_1)
exponential (l=2 SCALE=&ParamEXP1_1);
ods output GoodnessOfFit=results.Goodness_1;
run;
proc print data=results.Goodness_1;
在运行前面的代码之后,我得到了“结果”,它为我提供了直方图和其他关于测试的描述性信息。我正在寻找一种方法,使这个“结果”打印只显示最后一行添加的“过程打印”对应的最后一部分
提前谢谢 如果您不希望从
PROC UNIVARIATE
向屏幕(结果窗口)输出,那么最简单的答案是:
ods select none;
proc univariate ... ;
run;
ods select all;
proc print ... ;
run;
ods选择无代码>告诉ODS不要进行任何ODS输出。你仍然会得到你的ODS输出,尽管之后会有
ods select none;
proc univariate data=sashelp.class;
var height;
histogram name='univhist' /
lognormal (l=1 color=red )
gamma (l=1 color=red )
exponential (l=2 );
ods output GoodnessOfFit=Goodness_1;
run;
ods select all;
proc print data=Goodness_1;
run;
现在,你会注意到你没有得到你的直方图;那个更难。不幸的是,它在每次运行时都会更改名称,即使使用name=选项,也只能在第一次运行时才起作用。您需要使用PROC GREPLAY
删除它
proc greplay nofs igout=work.gseg;
delete 'univhist';
run; quit;
(假设UNIVHIST
是您分配给它的名称。)如果您不想从PROC UNIVARIATE
向屏幕(结果窗口)输出,那么最简单的答案是:
ods select none;
proc univariate ... ;
run;
ods select all;
proc print ... ;
run;
ods选择无代码>告诉ODS不要进行任何ODS输出。你仍然会得到你的ODS输出,尽管之后会有
ods select none;
proc univariate data=sashelp.class;
var height;
histogram name='univhist' /
lognormal (l=1 color=red )
gamma (l=1 color=red )
exponential (l=2 );
ods output GoodnessOfFit=Goodness_1;
run;
ods select all;
proc print data=Goodness_1;
run;
现在,你会注意到你没有得到你的直方图;那个更难。不幸的是,它在每次运行时都会更改名称,即使使用name=选项,也只能在第一次运行时才起作用。您需要使用PROC GREPLAY
删除它
proc greplay nofs igout=work.gseg;
delete 'univhist';
run; quit;
(假设UNIVHIST
是您指定的名称。)ODS选择是标准方法,但我看到您已经注释掉了该部分,所以我们可以假设这不起作用吗?嗨@Reeza!是的,不幸的是,它为每个分布提供了分区的数据。另一方面,“GoodnessOfFit”表给出了这些表的摘要…ODS SELECT是标准方法,但我看到您已经注释了该部分,所以我们可以假设这不起作用吗?嗨@Reeza!是的,不幸的是,它为每个分布提供了分区的数据。另一方面,“GoodnessOfFit”表给出了这些表的摘要…谢谢Joe!成功了!谢谢你,乔!成功了!