举个例子:
data ex(drop=i j);
array x(5);
do i=1 to 5;
do j=1 to i;
if i=j then x(i)=0;
else x(j)=ranuni(0);
end;
output;
end;
run;
proc cluster data=ex(type=distance) method=ward outtree=tree;/*type=distance代表数据集是距离矩阵*/
var x1-x5;
run;
proc tree data=tree hor;
run;