?
Solved

Compute cluster centroid

Posted on 2011-02-24
2
Medium Priority
?
380 Views
Last Modified: 2012-05-11
How can i compute the center of a class?
if each class has many many elements.
0
Comment
Question by:dadadude
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 5

Expert Comment

by:Ultra_Master
ID: 34972167
Have a look here for various methods:
http://en.wikipedia.org/wiki/Cluster_analysis
0
 
LVL 37

Accepted Solution

by:
TommySzalapski earned 2000 total points
ID: 34987452
The centroid is generally calculated as the average of all the points. I assume your classes have X,Y coordinates in there somewhere? (or X,Y,Z, or something). Just take the average of each and that's the centroid.

If you need to have one existing element be the centroid, then just use euclidean distance to find the closest one to the average location.

This is the standard way of doing it in almost all cases. You could also take the element that has the least total distance from all the others, but that takes a lot longer and will usually give you the same one anyway (maybe always).
0

Featured Post

Get proactive database performance tuning online

At Percona’s web store you can order full Percona Database Performance Audit in minutes. Find out the health of your database, and how to improve it. Pay online with a credit card. Improve your database performance now!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This algorithm (in C#) will resize any image down to a given size while maintaining the original aspect ratio. The maximum width and max height are both optional but if neither are given, the original image is returned. This example is designed t…
Iteration: Iteration is repetition of a process. A student who goes to school repeats the process of going to school everyday until graduation. We go to grocery store at least once or twice a month to buy products. We repeat this process every mont…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …
Suggested Courses

764 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question