I've a range of data values. I want to split it into ranges, say 3 ranges, based on the value. For ex: assume my data values look like this
1669
2653
2662
2669
2701
2711
2748
2770
2821
2832
2848
2850
2855
2859
2868
2893
2908
2922
2939
2968
2992
3005
3025
3026
3031
3033
3034
3036
3053
3073
3087
3087
3099
3128
3128
3131
3133
3140
3174
3182
3182
3189
3204
3204
3214
3219
3224
3225
3236
3244
3272
3295
3295
3296
3299
3305
3305
3402
My end goal is to be able to cleverly determine the low-medium-high from this set - meaning, I need code to find out which will 2 good boundary values - for something like <2600, >=2600 to 3000, >=3000. Something like K-means clustering... The set of values will always change, and may be even in 10 or 100s, instead of 1000s here.
NTILE in SQL breaks into equal buckets and hence does not fit my requirement. Any ideas ?