PROC CORR Spearman, Kendall's tau-b and Hoeffding's statistics might differ from previous SAS® releases


PROC CORR might generate different results for the following rank-based statistics beginning with SAS® 9.4TS1M1:

In prior releases, PROC CORR compares values directly. Due to machine dependent and numerical precision issues, sufficiently close values might be treated as different values. This is the same approach used by PROC RANK. Beginning in SAS 9.4TS1M1, PROC CORR includes a fuzz factor when comparing values, so that sufficiently close values are treated as the same values.

The following example demonstrates this:

data a;
do x=1 to 18;
y= 10 - 10**-x;
output;
end;
run;
proc rank data=a out=a1;
var y;
ranks yrank;
run;
proc print;
run;

A table with x, y, and rank columns.

proc corr data=a1 spearman kendall hoeffding;
var x;
with y yrank;
run;

Prior to SAS 9.4TS1M1, PROC CORR treats the rankings the same as PROC RANK and generates these results:

The Spearman Correlation Coefficients, Kendall Tau b Correlation Coefficients, and Hodeffing Dependence Coefficients tables

Beginning in SAS 9.4TS1M1, PROC CORR generates the following:

The Spearman Correlation Coefficients, Kendall Tau b Correlation Coefficients, and Hodeffing Dependence Coefficients tables

If desired, you can reproduce previous results in SAS 9.4 TS1M1 and later by using the ranks computed in PROC RANK instead of the raw data.