BookmarkSubscribeRSS Feed
ria_tran
Calcite | Level 5

Hi all, 

Can you please explain how the initial seed can be obtained so that clustering can be repeated every run using the FASTCLUS and HPCLUS procedures (https://communities.sas.com/t5/SAS-Communities-Library/Tip-K-means-clustering-in-SAS-comparing-PROC-... ?

Many thanks.

3 REPLIES 3
PGStats
Opal | Level 21

I couldn't follow the link you provided.

Try running a zero iteration clustering step to generate reusable seeds

 

proc fastclus data=sashelp.iris maxc=5 maxiter=0 outseed=seeds;
   var SepalLength SepalWidth PetalLength PetalWidth;
run;

and then reuse those seeds in subsequent clustering runs

 

proc fastclus data=sashelp.iris maxc=3 maxiter=100 seed=seeds;
   var SepalLength SepalWidth PetalLength PetalWidth;
run;

 

PG
ria_tran
Calcite | Level 5

Hi PGStats, 

Thank you for your response. The link is: https://communities.sas.com/t5/SAS-Communities-Library/Tip-K-means-clustering-in-SAS-comparing-PROC-...

I was wondering if there was a way to derive the optimal seed for the FASTCLUS and HPCLUS procedures combined, as demonstrated in part 3 of the link.

Many thanks, 
Ria. 

PGStats
Opal | Level 21

I don't have access to EM. But beware of this: The word seed has different meanings for FASTCLUS and HPCLUS. For the former it is a set of cluster centroids. For the later it is a starting number for pseudo-random number generation. 

Part 3 of the link proposes a way to select the optimal number of clusters (k) using HPCLUS and then to feed that number into FASTCLUS to get better clusters. In my view, it is only worth doing that for large problems. For smaller problems, running FASTCLUS reperatedly over a range of k-values does the job.

PG

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 3 replies
  • 1616 views
  • 1 like
  • 2 in conversation