[Submitted on 23 Nov 2026 ( v1 ), last revised 24 Nov 2026 (this version, v2)]
Title: $K$-Midranks: A robust clustering algorithm for heavy-tailed data with applications to spectroscopy and finance
Abstract: Clustering data with extreme observations and heavy tails can be challenging for methods that rely on distances between raw observations or specific distributional assumptions. We introduce $K$-midranks, a clustering method that replaces observations with coordinatewise ranks and partitions the transformed data using a procedure analogous to $K$-means. This transformation reduces the influence of extreme values while preserving the ordering of observations within each variable. We evaluate $K$-midranks against $K$-means, $K$-medoids, and mixture models based on Gaussian, Student's t, Cauchy, and generalized hyperbolic distributions through simulation studies, and provide some theoretical properties. $K$-midranks generally outperforms the competing methods on Cauchy-shifted data. In contrast, $K$-means and model-based methods perform better on Gaussian data and Student's t data with three degrees of freedom. We demonstrate the method's practical use in grouping samples based on Raman and LIBS spectra and clustering S\&P 500 stocks according to their returns. $K$-midranks achieves competitive performance with model-based methods in the spectroscopy applications and the best performance among the methods considered in the stock-return application. These findings suggest that $K$-midranks provides a useful alternative for clustering data with Cauchy-like heavy tails. An R package implementing the proposed method is available.
| Subjects: | Methodology (stat.ME) ; Machine Learning (stat.ML) |
| Comments: | 36 pages with a 6-page supplement. Supplementary material is now available as a PDF for easier access. The main manuscript remains unchanged |
| Cite as: | arXiv:2611.30953 [cs.CV] |