select groups of data that is has high frequency

2 views (last 30 days)
how do i automatically select group of data that has high frequency?. for example, in the picture i've attached, the group of data is within (600 to 800 in x-axis).
Thank you

Answers (1)

Walter Roberson
Walter Roberson on 12 Mar 2017
You have not defined "groups".
The mean of your data is 634 and the median is 629, so it would be valid to say that the highest frequency should be near 630 or so, rather than having 600 being the beginning of the high frequency range.
You can find the mean() and standard deviation, and you could say that the bounds should be from mean - 1 * standard to mean + 1 * standard. That would get you from about 480 to 788.
You could ask to kmeans 3 clusters, under the assumption that if you have a leading group not part of the high frequency area, that you have a trailing group that is not part of the high frequency area.
You could ask to kmeans 2 clusters. That gives a relatively clear visual separation, but gives coordinates starting from 583 for the right-hand cluster, not 600. That difference of 583 to 600 is important.
You only have 27 data points, so the boundaries are very sensitive, which makes it all the more important that you have clear guidelines as to what "groups" are for your purpose.


Find more on Statistics and Machine Learning Toolbox in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by