Date: Tue, 14 Dec 2004 07:45:38 -0500
Reply-To: Jay Weedon <jweedon@EARTHLINK.NET>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Jay Weedon <jweedon@EARTHLINK.NET>
Organization: http://newsguy.com
Subject: Re: How to find center of cluster
Content-Type: text/plain; charset=us-ascii
On 12 Dec 2004 22:27:50 -0800, brian@homeboys.dk (B Schwartz) wrote:
>I have a range of predefined clusters in a 4 dimensional space (one
>cluster for each customer type). My problem is I want to calculate the
>CENTER OF EACH CLUSTER in order to find the distances between the
>clusters.
>1) How do I do that - theoretically ?
Depends on what you mean by "center". The commonest definition is
"centroid", which is simply the vector of means of X,Y,Z,T for cases
belonging to the cluster.
And on what you mean by "distance". The commonest definition is
Euclidean distance, which is the square root of the sum of squared
differences, so if your centroids are [X1,Y1,Z1,T1] & [X2,Y2,Z2,T2]
then the Euclidean distance between them is
Sqrt[ (X1-X2)**2+(Y1-Y2)**2+(Z1-Z2)**2+(T1-T2)**2].
JW
|