IDEAS home Printed from https://ideas.repec.org/a/kap/compec/v67y2026i2d10.1007_s10614-025-10879-3.html

An Identification and Estimation of Stock Price Pattern Equations using K-Means

Author

Listed:
  • Matej Steinbacher

    (Pixlifai)

  • Matjaž Steinbacher

    (Fund for Financing the Decommissioning of the Krško Nuclear Power Plant and Disposal of Radioactive Waste)

  • Mitja Steinbacher

    (Catholic Institute, Faculty of Law and Business Studies)

Abstract

Clustering is a method of grouping similar objects together. Numerous clustering methods have been invented to date. However, with the advent of machine learning technologies and with the availability of large scale datasets, clustering has been revived. This paper applies K-means clustering to study price patterns in a large scale dataset of stock prices. It is novel in that it, among other things, reshapes the large scale complex dataset into a sequence of chained collocations of stock prices, which are then clustered at these collocation points. The approach managed to extract several stylized price patterns by a diverse set of clusters of different sizes and shapes, exhibiting linear independence and power-law distribution in size. Empirical estimations of these and other features support the validity and robustness of the clustering methodology used in this paper. Altogether, the paper makes a strong case in favor of the K-means clustering for the study of stock-price patterns.

Suggested Citation

  • Matej Steinbacher & Matjaž Steinbacher & Mitja Steinbacher, 2026. "An Identification and Estimation of Stock Price Pattern Equations using K-Means," Computational Economics, Springer;Society for Computational Economics, vol. 67(2), pages 511-554, February.
  • Handle: RePEc:kap:compec:v:67:y:2026:i:2:d:10.1007_s10614-025-10879-3
    DOI: 10.1007/s10614-025-10879-3
    as

    Download full text from publisher

    File URL: http://link.springer.com/10.1007/s10614-025-10879-3
    File Function: Abstract
    Download Restriction: Access to the full text of the articles in this series is restricted.

    File URL: https://libkey.io/10.1007/s10614-025-10879-3?utm_source=ideas
    LibKey link: if access is restricted and if your library uses this service, LibKey will redirect you to where you can use your library subscription to access this item
    ---><---

    As the access to this document is restricted, you may want to

    for a different version of it.

    References listed on IDEAS

    as
    1. Cheol‐Ho Park & Scott H. Irwin, 2007. "What Do We Know About The Profitability Of Technical Analysis?," Journal of Economic Surveys, Wiley Blackwell, vol. 21(4), pages 786-826, September.
    2. Kuhn, Harold W., 2012. "A tale of three eras: The discovery and rediscovery of the Hungarian Method," European Journal of Operational Research, Elsevier, vol. 219(3), pages 641-651.
    3. Andrew Detzel & Hong Liu & Jack Strauss & Guofu Zhou & Yingzi Zhu, 2021. "Learning and predictability via technical analysis: Evidence from bitcoin and stocks with hard‐to‐value fundamentals," Financial Management, Financial Management Association International, vol. 50(1), pages 107-137, March.
    4. Frankel, Jeffrey A & Froot, Kenneth A, 1990. "Chartists, Fundamentalists, and Trading in the Foreign Exchange Market," American Economic Review, American Economic Association, vol. 80(2), pages 181-185, May.
    5. Jian Huang & Junyi Chai & Stella Cho, 2020. "Deep learning in finance and banking: A literature review and classification," Frontiers of Business Research in China, Springer, vol. 14(1), pages 1-24, December.
    6. Rabbani, Quazzafi & Khan, Aamir & Quddoos, Abdul, 2019. "Modified Hungarian method for unbalanced assignment problem with multiple jobs," Applied Mathematics and Computation, Elsevier, vol. 361(C), pages 493-498.
    7. Menkhoff, Lukas, 2010. "The use of technical analysis by fund managers: International evidence," Journal of Banking & Finance, Elsevier, vol. 34(11), pages 2573-2586, November.
    8. Madhavan, Ananth, 2000. "Market microstructure: A survey," Journal of Financial Markets, Elsevier, vol. 3(3), pages 205-258, August.
    9. H. W. Kuhn, 1955. "The Hungarian method for the assignment problem," Naval Research Logistics Quarterly, John Wiley & Sons, vol. 2(1‐2), pages 83-97, March.
    10. Stephen Johnson, 1967. "Hierarchical clustering schemes," Psychometrika, Springer;The Psychometric Society, vol. 32(3), pages 241-254, September.
    11. Christopher J. Neely & David E. Rapach & Jun Tu & Guofu Zhou, 2014. "Forecasting the Equity Risk Premium: The Role of Technical Indicators," Management Science, INFORMS, vol. 60(7), pages 1772-1791, July.
    12. Andersen, Torben G. & Bollerslev, Tim & Diebold, Francis X. & Ebens, Heiko, 2001. "The distribution of realized stock return volatility," Journal of Financial Economics, Elsevier, vol. 61(1), pages 43-76, July.
    13. J. Gower, 1975. "Generalized procrustes analysis," Psychometrika, Springer;The Psychometric Society, vol. 40(1), pages 33-51, March.
    14. Brad M. Barber & Xing Huang & Terrance Odean & Christopher Schwarz, 2022. "Attention‐Induced Trading and Returns: Evidence from Robinhood Users," Journal of Finance, American Finance Association, vol. 77(6), pages 3141-3190, December.
    15. Leland E. Farmer & Lawrence Schmidt & Allan Timmermann, 2023. "Pockets of Predictability," Journal of Finance, American Finance Association, vol. 78(3), pages 1279-1341, June.
    16. Andrew W. Lo & Harry Mamaysky & Jiang Wang, 2000. "Foundations of Technical Analysis: Computational Algorithms, Statistical Inference, and Empirical Implementation," Journal of Finance, American Finance Association, vol. 55(4), pages 1705-1765, August.
    17. Gerritsen, Dirk F. & Bouri, Elie & Ramezanifar, Ehsan & Roubaud, David, 2020. "The profitability of technical trading rules in the Bitcoin market," Finance Research Letters, Elsevier, vol. 34(C).
    18. Taylor, Mark P. & Allen, Helen, 1992. "The use of technical analysis in the foreign exchange market," Journal of International Money and Finance, Elsevier, vol. 11(3), pages 304-314, June.
    19. Hoffmann, Arvid O.I. & Shefrin, Hersh, 2014. "Technical analysis and individual investors," Journal of Economic Behavior & Organization, Elsevier, vol. 107(PB), pages 487-511.
    20. Andrew W. Lo, A. Craig MacKinlay, 1988. "Stock Market Prices do not Follow Random Walks: Evidence from a Simple Specification Test," The Review of Financial Studies, Society for Financial Studies, vol. 1(1), pages 41-66.
    21. Andersen, Torben G. & Bollerslev, Tim & Cai, Jun, 2000. "Intraday and interday volatility in the Japanese stock market," Journal of International Financial Markets, Institutions and Money, Elsevier, vol. 10(2), pages 107-130, June.
    22. Fang, Jiali & Qin, Yafeng & Jacobsen, Ben, 2014. "Technical market indicators: An overview," Journal of Behavioral and Experimental Finance, Elsevier, vol. 4(C), pages 25-56.
    23. Brock, William & Lakonishok, Josef & LeBaron, Blake, 1992. "Simple Technical Trading Rules and the Stochastic Properties of Stock Returns," Journal of Finance, American Finance Association, vol. 47(5), pages 1731-1764, December.
    24. Harry V. Roberts, 1959. "Stock‐Market “Patterns” And Financial Analysis: Methodological Suggestions," Journal of Finance, American Finance Association, vol. 14(1), pages 1-10, March.
    Full references (including those not matched with items on IDEAS)

    Most related items

    These are the items that most often cite the same works as this one and are cited by the same works as this one.
    1. Farias Nazário, Rodolfo Toríbio & e Silva, Jéssica Lima & Sobreiro, Vinicius Amorim & Kimura, Herbert, 2017. "A literature review of technical analysis on stock markets," The Quarterly Review of Economics and Finance, Elsevier, vol. 66(C), pages 115-126.
    2. Christopher J. Neely & Paul A. Weller, 2011. "Technical analysis in the foreign exchange market," Working Papers 2011-001, Federal Reserve Bank of St. Louis.
    3. Thierry Warin & Aleksandar Stojkov, 2021. "Machine Learning in Finance: A Metadata-Based Systematic Review of the Literature," JRFM, MDPI, vol. 14(7), pages 1-31, July.
    4. Hung, Chiayu & Lai, Hung-Neng, 2022. "Information asymmetry and the profitability of technical analysis," Journal of Banking & Finance, Elsevier, vol. 134(C).
    5. Gerritsen, Dirk F., 2016. "Are chartists artists? The determinants and profitability of recommendations based on technical analysis," International Review of Financial Analysis, Elsevier, vol. 47(C), pages 179-196.
    6. Fong, Tom Pak Wing & Wu, Shui Tang, 2020. "Predictability in sovereign bond returns using technical trading rules: Do developed and emerging markets differ?," The North American Journal of Economics and Finance, Elsevier, vol. 51(C).
    7. Souropanis, Ioannis & Vivian, Andrew, 2023. "Forecasting realized volatility with wavelet decomposition," Journal of Empirical Finance, Elsevier, vol. 74(C).
    8. Ebert, Sebastian & Hilpert, Christian, 2019. "Skewness preference and the popularity of technical analysis," Journal of Banking & Finance, Elsevier, vol. 109(C).
    9. Jying‐Nan Wang & Hung‐Chun Liu & Jiangze Du & Yuan‐Teng Hsu, 2019. "Economic benefits of technical analysis in portfolio management: Evidence from global stock markets," International Journal of Finance & Economics, John Wiley & Sons, Ltd., vol. 24(2), pages 890-902, April.
    10. Detlef Seese & Christof Weinhardt & Frank Schlottmann (ed.), 2008. "Handbook on Information Technology in Finance," International Handbooks on Information Systems, Springer, number 978-3-540-49487-4, October.
    11. Panopoulou, Ekaterini & Souropanis, Ioannis, 2019. "The role of technical indicators in exchange rate forecasting," Journal of Empirical Finance, Elsevier, vol. 53(C), pages 197-221.
    12. Ryan Flugum, 2021. "The trend is an analyst's friend: Analyst recommendations and market technicals," The Financial Review, Eastern Finance Association, vol. 56(2), pages 301-330, May.
    13. Bekiros, Stelios D., 2015. "Heuristic learning in intraday trading under uncertainty," Journal of Empirical Finance, Elsevier, vol. 30(C), pages 34-49.
    14. Xiaoye Jin, 2022. "Evaluating the predictive power of intraday technical trading in China's crude oil market," Journal of Forecasting, John Wiley & Sons, Ltd., vol. 41(7), pages 1416-1432, November.
    15. Mingwei Sun & Paskalis Glabadanidis, 2022. "Can technical indicators predict the Chinese equity risk premium?," International Review of Finance, International Review of Finance Ltd., vol. 22(1), pages 114-142, March.
    16. Boris Kriuk & Logic Ng & Zarif Al Hossain, 2025. "DeepSupp: Attention-Driven Correlation Pattern Analysis for Dynamic Time Series Support and Resistance Levels Identification," Papers 2507.01971, arXiv.org.
    17. Shynkevich, Andrei, 2012. "Performance of technical analysis in growth and small cap segments of the US equity market," Journal of Banking & Finance, Elsevier, vol. 36(1), pages 193-208.
    18. Bley, Jorg & Saad, Mohsen, 2020. "An analysis of technical trading rules: The case of MENA markets," Finance Research Letters, Elsevier, vol. 33(C).
    19. Cakici, Nusret & Zaremba, Adam, 2025. "Accounting vs technical information: what matters more for stock return predictability?," Journal of International Financial Markets, Institutions and Money, Elsevier, vol. 104(C).
    20. Hoffmann, Arvid O.I. & Shefrin, Hersh, 2014. "Technical analysis and individual investors," Journal of Economic Behavior & Organization, Elsevier, vol. 107(PB), pages 487-511.

    More about this item

    Keywords

    ;
    ;
    ;

    Statistics

    Access and download statistics

    Corrections

    All material on this site has been provided by the respective publishers and authors. You can help correct errors and omissions. When requesting a correction, please mention this item's handle: RePEc:kap:compec:v:67:y:2026:i:2:d:10.1007_s10614-025-10879-3. See general information about how to correct material in RePEc.

    If you have authored this item and are not yet registered with RePEc, we encourage you to do it here. This allows to link your profile to this item. It also allows you to accept potential citations to this item that we are uncertain about.

    If CitEc recognized a bibliographic reference but did not link an item in RePEc to it, you can help with this form .

    If you know of missing items citing this one, you can help us creating those links by adding the relevant references in the same way as above, for each refering item. If you are a registered author of this item, you may also want to check the "citations" tab in your RePEc Author Service profile, as there may be some citations waiting for confirmation.

    For technical questions regarding this item, or to correct its authors, title, abstract, bibliographic or download information, contact: Sonal Shukla or Springer Nature Abstracting and Indexing (email available below). General contact details of provider: http://www.springer.com .

    Please note that corrections may take a couple of weeks to filter through the various RePEc services.

    IDEAS is a RePEc service. RePEc uses bibliographic data supplied by the respective publishers.