10-04-2011 10:47 PM
Hi. I am doing a Cluster analysis. I ended up doing Hierarchial Clustering by
Wards method for my binary(dichotomous) variables dataset.
I would like to know how I can get a scatter plot showing the three clusters
neatly in different symbols and colors. I am struggling with this. Can you
please help me.
10-05-2011 02:36 AM
Could this help you?
SYMBOL1 V=circle C=black;
SYMBOL2 V=star C=red;
SYMBOL3 V=diamond C=blue;
proc gplot data=test;
More info about symbol statement on:
10-05-2011 09:43 AM
I tried doing this, but I need a cluster plot with all the 33 variables shown across the plot on three different clusters. I have no idea how I should be plotting this. ? Could someone help?
10-05-2011 05:24 PM
With binary data, assuming no missing values, all you can show is the number of observations having each variable's state in every cluster, i.e. the strength or importance of each variable in the clusters. You could do this with three horizontal bar graphs side by side. Something along the lines of:
/* Assuming dataset myData contains variables
id: unique observation id,
clusId: cluster to which the observation belongs,
v1 to v33: dichotomous variables with values 0 or 1 */
proc sort data=myData; by clusId id; run;
proc transpose data=myData out=myTData name=myVariable;
by clusId id;
ods graphics on;
proc sgpanel data=myTData;
panelby clusId / layout=columnlattice;
hbar myVariable / response=col1 stat=sum;