Clustering/sorting of close data points
9 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Hello all,
I would like to bundle up some close data points. This is how my data looks like: 214981 366893 455877 455877 455877 455878 889359 889359 1443570 1443570........
Can anybody suggest an easy way to do this?
Thanks.
Raju
6 comentarios
Walter Roberson
el 11 de Jul. de 2022
Consider for example your value 455877 : what is the minimum and maximum value that you wish to be considered to be the same group as 455877, if those values were encountered as data?
Consider also 214981: what is the minimum and maximum value that you wish to be considered to be the same group as 214981, if those values were encountered as data?
I ask about two different values because the boundary for higher values might not have the same range as for lower value. For example in [1 8 25] the 8 might be considered to be relatively far from the "1" (since it is 8 times the value), whereas by the time you got to 200000, the value 200010 might be considered "close" to 200000 since the difference is pretty small relative to the value.
Respuestas (1)
Image Analyst
el 11 de Jul. de 2022
Editada: Image Analyst
el 12 de Jul. de 2022
This is really too broad a question to answer yet. You haven't even plotted your data or told us what "close" is. I suggest you start by reading this page:
Maybe you can simply take the histogram.
If you have any more questions, then attach your data and code to read it in with the paperclip icon after you read this:
This is how I'd classify your data. Basically you can do it manually for such few data points. For far more data points, you can try the Classification Learner App on the apps tab of the tool ribbon. Even for these few, it looks like SVM might be good. But please attach far more data so we can find the best classifier.
data = [214981 366893 455877 455877 455877 455878 889359 889359 1443570 1443570]';
classes = [1,1,1,1,1,1,2,2,3,3]';
plot(data, 'b.', 'MarkerSize', 30);
grid on;
2 comentarios
Image Analyst
el 12 de Jul. de 2022
Exactly how are you seeing clusters in that data?
s = load('raju.mat')
toa = s.ToA;
classes = [1,1,1,1,1,1,2,2,3,3]';
plot(toa, 'b.', 'MarkerSize', 10);
grid on;
xlabel('Index of Vector')
ylabel('Value of toa')
Ver también
Categorías
Más información sobre Discriminant Analysis en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!