Morning,
As per the attached Document illustrates, i have a Final Dataset of identified clusters from a number of PROC Fastclus statements on broken down data prior to this - essentially this FINAL_CLUSters is my dataset with the required NEWCLUSTERS variable indicating the wanted Cluster.
Now i need to get the SEED stats using OUTSTAT= , for application of these clusters to future monthly observations, i need the centre points of my Clusters.
However, when i use the PROC FASTCLUS on this final_clusters dataset , my cluster numbers change (as per the diagram on the attached file), they are no longer 1,2,3,4,5,6 but rather NEWCLUSTER 1 is now split into CLUSTERS 6 &1 - how can i keep my same clusters from my chosen NEWCLUSTERS and identify the seeds this way:
proc fastclus data=FINAL_CLUSters maxclusters=6 maxiter=100 converge=0
out=prelimvol;
var VOLUME: LOGVAL_MEAN: LOGVAL_Sum:;
run;
proc sort data=mylib.myCLUSds; by NEWCLUSTER; run;
proc fastclus data=mylib.myCLUSds
maxclusters=1 maxiter=0
outstat=work.abc outseed=work.def out=work.xyz;
/* OUTSEED= or MEAN= */
id name;
by NEWCLUSTER;
var _NUMERIC_;
*var VOLUME: LOGVAL_Mean: LOGVAL_Sum: ;
run;
Cheers,
Koen
Post some sample data, so we can test it. and don't forget post output either. data prelimvol; set prelimvol; if col1 not =: 'cluster' then group+1; run;
proc sort data=mylib.myCLUSds; by NEWCLUSTER; run;
proc fastclus data=mylib.myCLUSds
maxclusters=1 maxiter=0
outstat=work.abc outseed=work.def out=work.xyz;
/* OUTSEED= or MEAN= */
id name;
by NEWCLUSTER;
var _NUMERIC_;
*var VOLUME: LOGVAL_Mean: LOGVAL_Sum: ;
run;
Cheers,
Koen
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.
Find more tutorials on the SAS Users YouTube channel.