公卫百科  > 所属分类  >  SAS   
[0] 评论[0] 编辑

Proc Rank

Proc rank computes the ranks of the values of numeric variables. The ranks can then be used to conduct nonparametric statistical tests, among other uses. See also proc univariate and proc npar1way for conducting nonparametric tests. Example: 公卫考场


proc rank
 data=stuff
 out=newstuff /* highly recommended */
 descending
 fraction
 ties=high;
ranks rankedx rankedy;
var x y;
run;

公卫百科


The data= option specifies the SAS data set containing the variables for which ranks are to be computed. If not specified the ranks will be placed in a data set named DATAn where n is an integer. 公卫家园

The out= option specifies the name of the SAS data set that will contain the ranks. 公卫家园

The descending option creates rankings with the largest value having rank 1. The default gives the smallest value rank 1. 公卫论坛

The fraction option divides each rank by the number of nonmissing values taken by the variable.

公卫百科

The ties= option determines how tied values are assigned ranks. The default ties=mean uses midranks; ties=low uses the smallest of the corresponding ranks; ties=high uses the largest of the corresponding ranks. Using ties=high together with the fraction option produces the values of the empirical distribution function of the sample.

公卫家园

The ranks statement assigns names to the variables holding the ranks of variables listed in the var statement. The first name in the ranks statement is the name of the variable in the out= data set which holds the ranks of the first variable in the var statement, and so on. If the ranks statement is NOT used the variable names in the original data set are used as the names of variables in the out= data set with the values replaced by the ranks. 公卫考场

The var statement specifies the variables in the SAS data set for which ranks are to be computed. If omitted, all numeric variables in the data set are ranked. Variables not listed in the var statement are passed unchanged to the out= data set. If the ranks statement is NOT used the variable names in the original data set are used as the names of variables in the out= data set with the values replaced by the ranks. If the ranks statement is used the var statement MUST be used.

公卫考场

Other options are available to compute normal scores and Savage (exponential) scores. A by statement can also be used. For further information see the SAS Procedures Guide. 公卫考场

附件列表


0

词条内容仅供参考,如果您需要解决具体问题
(尤其在法律、医学等领域),建议您咨询相关领域专业人士。

如果您认为本词条还有待完善,请 编辑

上一篇 老年系数    下一篇 检验功效

标签

同义词

暂无同义词