IDEAS home Printed from https://ideas.repec.org/p/arx/papers/1902.08684.html
   My bibliography  Save this paper

Discovering Language of the Stocks

Author

Listed:
  • Marko Pov{z}enel
  • Dejan Lavbiv{c}

Abstract

Stock prediction has always been attractive area for researchers and investors since the financial gains can be substantial. However, stock prediction can be a challenging task since stocks are influenced by a multitude of factors whose influence vary rapidly through time. This paper proposes a novel approach (Word2Vec) for stock trend prediction combining NLP and Japanese candlesticks. First, we create a simple language of Japanese candlesticks from the source OHLC data. Then, sentences of words are used to train the NLP Word2Vec model where training data classification also takes into account trading commissions. Finally, the model is used to predict trading actions. The proposed approach was compared to three trading models Buy & Hold, MA and MACD according to the yield achieved. We first evaluated Word2Vec on three shares of Apple, Microsoft and Coca-Cola where it outperformed the comparative models. Next we evaluated Word2Vec on stocks from Russell Top 50 Index where our Word2Vec method was also very successful in test phase and only fall behind the Buy & Hold method in validation phase. Word2Vec achieved positive results in all scenarios while the average yields of MA and MACD were still lower compared to Word2Vec.

Suggested Citation

  • Marko Pov{z}enel & Dejan Lavbiv{c}, 2019. "Discovering Language of the Stocks," Papers 1902.08684, arXiv.org.
  • Handle: RePEc:arx:papers:1902.08684
    as

    Download full text from publisher

    File URL: http://arxiv.org/pdf/1902.08684
    File Function: Latest version
    Download Restriction: no
    ---><---

    References listed on IDEAS

    as
    1. Tsung-Hsun Lu & Yung-Ming Shiu, 2012. "Tests for Two-Day Candlestick Patterns in the Emerging Equity Market of Taiwan," Emerging Markets Finance and Trade, Taylor & Francis Journals, vol. 48(0), pages 41-57, January.
    2. Burton G. Malkiel, 2003. "The Efficient Market Hypothesis and Its Critics," Working Papers 111, Princeton University, Department of Economics, Center for Economic Policy Studies..
    3. Cristina Abad & Sten A. Thore & Joaquina Laffarga, 2004. "Fundamental analysis of stocks by two-stage DEA," Managerial and Decision Economics, John Wiley & Sons, Ltd., vol. 25(5), pages 231-241.
    4. repec:pri:cepsud:91malkiel is not listed on IDEAS
    5. Lu, Tsung-Hsun, 2014. "The profitability of candlestick charting in the Taiwan stock market," Pacific-Basin Finance Journal, Elsevier, vol. 26(C), pages 65-78.
    6. 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.
    7. Tay, Francis E. H. & Cao, Lijuan, 2001. "Application of support vector machines in financial time series forecasting," Omega, Elsevier, vol. 29(4), pages 309-317, August.
    8. Burton G. Malkiel, 2003. "The Efficient Market Hypothesis and Its Critics," Journal of Economic Perspectives, American Economic Association, vol. 17(1), pages 59-82, Winter.
    9. Burton G. Malkiel, 2003. "The Efficient Market Hypothesis and Its Critics," Working Papers 111, Princeton University, Department of Economics, Center for Economic Policy Studies..
    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. Ghada A. Altarawneh & Ahmad B. Hassanat & Ahmad S. Tarawneh & Ahmad Abadleh & Malek Alrashidi & Mansoor Alghamdi, 2022. "Stock Price Forecasting for Jordan Insurance Companies Amid the COVID-19 Pandemic Utilizing Off-the-Shelf Technical Analysis Methods," Economies, MDPI, vol. 10(2), pages 1-18, February.
    2. Park, Cheol-Ho & Irwin, Scott H., 2004. "The Profitability Of Technical Trading Rules In Us Futures Markets: A Data Snooping Free Test," 2004 Conference, April 19-20, 2004, St. Louis, Missouri 19011, NCR-134 Conference on Applied Commodity Price Analysis, Forecasting, and Market Risk Management.
    3. Svitlana Galeshchuk, 2017. "Technological bias at the exchange rate market," Intelligent Systems in Accounting, Finance and Management, John Wiley & Sons, Ltd., vol. 24(2-3), pages 80-86, April.
    4. Heni Boubaker & Giorgio Canarella & Rangan Gupta & Stephen M. Miller, 2023. "A Hybrid ARFIMA Wavelet Artificial Neural Network Model for DJIA Index Forecasting," Computational Economics, Springer;Society for Computational Economics, vol. 62(4), pages 1801-1843, December.
    5. Jaehun Chung & Yongmiao Hong, 2007. "Model-free evaluation of directional predictability in foreign exchange markets," Journal of Applied Econometrics, John Wiley & Sons, Ltd., vol. 22(5), pages 855-889.
    6. 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.
    7. Armin Shmilovici & Yoav Kahiri & Irad Ben-Gal & Shmuel Hauser, 2009. "Measuring the Efficiency of the Intraday Forex Market with a Universal Data Compression Algorithm," Computational Economics, Springer;Society for Computational Economics, vol. 33(2), pages 131-154, March.
    8. Ken Chung & Anthony Bellotti, 2021. "Evidence and Behaviour of Support and Resistance Levels in Financial Time Series," Papers 2101.07410, arXiv.org.
    9. Roscoe, Philip & Howorth, Carole, 2009. "Identification through technical analysis: A study of charting and UK non-professional investors," Accounting, Organizations and Society, Elsevier, vol. 34(2), pages 206-221, February.
    10. I. Marta Miranda García & María‐Jesús Segovia‐Vargas & Usue Mori & José A. Lozano, 2023. "Early prediction of Ibex 35 movements," Journal of Forecasting, John Wiley & Sons, Ltd., vol. 42(5), pages 1150-1166, August.
    11. Deniz Ersan & Chifumi Nishioka & Ansgar Scherp, 2020. "Comparison of machine learning methods for financial time series forecasting at the examples of over 10 years of daily and hourly data of DAX 30 and S&P 500," Journal of Computational Social Science, Springer, vol. 3(1), pages 103-133, April.
    12. 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.
    13. repec:wyi:journl:002068 is not listed on IDEAS
    14. David M. Ritzwoller & Joseph P. Romano, 2019. "Uncertainty in the Hot Hand Fallacy: Detecting Streaky Alternatives to Random Bernoulli Sequences," Papers 1908.01406, arXiv.org, revised Apr 2021.
    15. Chia-Lin Chang & Jukka Ilomäki & Hannu Laurila & Michael McAleer, 2018. "Long Run Returns Predictability and Volatility with Moving Averages," Risks, MDPI, vol. 6(4), pages 1-18, September.
    16. Bell, Peter N, 2013. "New Testing Procedures to Assess Market Efficiency with Trading Rules," MPRA Paper 46701, University Library of Munich, Germany.
    17. Jitka Veselá & Alžběta Zíková, 2022. "Are the Czech, Polish, German and Dutch markets taking a random walk? [Konají český, polský, německý a nizozemský trh náhodnou procházku?]," Český finanční a účetní časopis, Prague University of Economics and Business, vol. 2022(2), pages 19-38.
    18. Muchnik, Lev & Bunde, Armin & Havlin, Shlomo, 2009. "Long term memory in extreme returns of financial time series," Physica A: Statistical Mechanics and its Applications, Elsevier, vol. 388(19), pages 4145-4150.
    19. Nathan Jensen, 2007. "International institutions and market expectations: Stock price responses to the WTO ruling on the 2002 U.S. steel tariffs," The Review of International Organizations, Springer, vol. 2(3), pages 261-280, September.
    20. Ishani Chaudhuri & Parthajit Kayal, 2022. "Predicting Power of Ticker Search Volume in Indian Stock Market," Working Papers 2022-214, Madras School of Economics,Chennai,India.
    21. John Sabelhaus, 2005. "Alternative Methods for Projecting Equity Returns: Implications for Evaluating Social Security Reform Proposals," Risk Management and Insurance Review, American Risk and Insurance Association, vol. 8(1), pages 43-63, March.

    More about this item

    NEP fields

    This paper has been announced in the following NEP Reports:

    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:arx:papers:1902.08684. 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: arXiv administrators (email available below). General contact details of provider: http://arxiv.org/ .

    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.