Abstract
Intraday trading attempts to obtain a profit from the microstructure implicit in price data. Intraday trading implies many more transactions per stock compared to long term buy-and-hold strategies. As a consequence, transaction costs will have a more significant impact on the profitability. Furthermore, the application of existing long term portfolio selection algorithms for intraday trading cannot guarantee optimal stock selection. This implies that intraday trading strategies may require a different approach to stock selection for daily portfolios. In this work, we assume a symbiotic genetic programming framework that simultaneously coevolves the decision trees and technical indicators to generate trading signals. We generalize this approach to identify specific stocks for intraday trading using stock ranking heuristics: Moving Sharpe ratio and a Moving Average of Daily Returns. Specifically, the trading scenario adopted by this work assumes that a bag of available stocks exist. Our agent then has to both identify which subset of stocks to trade in the next trading day, and the specific buy-hold-sell decisions for each selected stock during real-time trading for the duration of the intraday period. A benchmarking comparison of the proposed ranking heuristics with stock selection performed using the well known Kelly Criterion is conducted and a strong preference for the proposed Moving Sharpe ratio demonstrated. Moreover, portfolios ranked by both the Moving Sharpe ratio and a Moving Average of Daily Returns perform significantly better than any of the comparator methods (buy-and-hold strategy, investment in the full set of 86 stocks, portfolios built from random stock selection and Kelly Criterion).
This is a preview of subscription content, access via your institution.



















Notes
‘Fundamental analysis’ performs a macro or strategic assessment of where a stock should be trading on any criteria except the behavior of price itself. The criteria often include the economic condition of the country in which the stock conducts business, monetary policy, and other “fundamental” elements [12].
‘Technical analysis’ is that which is applied to the price behavior of the stock to develop a trading decision, irrespective of fundamental factors [12].
‘Technical indicators’ are any class of metrics whose value is derived from generic price activity in a stock or asset. Technical indicators look to predict the future price levels, or simply the general price direction, of a security by looking at past patterns [12].
‘Candlestick’ is a type of price chart that displays the high, low, open, and closing prices of a trading asset (currency pair, stock, etc.) for a specific period of time (e.g., 1 min, 5 min, etc.). [12]
A stop loss is an order to buy or sell when the market moves to a specific price. A stop-loss order is designed to limit a loss when the price is moving in the opposite direction to the most recent buy or sell [12].
A take profit is an order to buy or sell when the market reaches a target price to fix the profit [12].
S is a number of stocks that can be traded in the daily portfolio (Fig. 1).
All stocks from the portfolio are held, as there is no basis for selecting a subset of specific stock.
Implies that each stock is invested in equally each day, subject to the 10% account balance and flat rate rules from Sect. 4.2.
Naturally, the recommended stock is free to change each day.
References
F. Allen, R. Karjalainen, Using genetic algorithms to find technical trading rules. J. Financ. Econ. 51, 245–271 (1999)
F.M. Bandi, J.R. Russell, Microstructure noise, realized variance, and optimal sampling. Rev. Financ. Stud. 75, 339–369 (2008)
J. Baz, H. Guo, An asset allocation primer: connecting Markowitz, Kelly and Risk Parity. Quantative Research, pp. 1–16 (2017)
E.P. Chan, Quantitative Trading: How to Build Your Own Algorithmic Trading Business (Wiley, London, 2009)
S. Chen, C. Yeh, Toward a computable approach to the efficient market hypothesis: an application of genetic programming. J. Econ. Dyn. Control 21, (1996)
I. Contreras, J.I. Hidalgo, L. Nuñez-Letamendía, J.M. Velasco, A meta-grammatical evolutionary process for portfolio selection and trading. Genet. Program Evolvable Mach. 18(4), 411–431 (2017)
V. DeMiguel, L. Garlappi, R. Uppal, Optimal versus naive diversification: How inefficient is the 1/n portfolio strategy? Rev. Financ. Stud. 22, 1915–1953 (2009)
N. Goumatianos, I. Christou, P. Lindgren, Stock selection system: building long/short portfolios using intraday patterns. Procedia Econ. Finance 5, 298–307 (2013)
G.N. Gregoriou, Handbook of High Frequency Trading (Academic Press, London, 2015)
Y. Ha, Algorithmic trading in limit order books for online portfolio selection. SSRN Electron. J. (2017)
M.I. Heywood, P. Lichodzijewski, Symbiogenesis as a mechanism for building complex adaptive systems: a review. In: Applications of Evolutionary Computation: Part I, LNCS, vol. 6024, pp. 51–60. Springer, Berlin (2010)
https://www.macrotrends.net/2489/nasdaq-composite-index-10-year-daily-chart
H. Iba, C.C. Aranha, Practical Applications of Evolutionary Computation to Financial Engineering, Adaptation, Learning, and Optimization, vol. 11 (Springer, Berlin, 2012)
R. Jagannathan, T. Ma, Risk reduction in large portfolios: why imposing the wrong constraints helps. J. Finance 58, 1651–1684 (2003)
G. Kim, S. Jung, The construction of the optimal investment portfolio using the Kelly Criterion. World J. Soc. Sci. 3(6), 15–26 (2013)
P.N. Kolm, R. Tütüncü, F.J. Fabozzi, 60 years of portfolio optimization: practical challenges and current trends. Eur. J. Oper. Res. 234, 356–371 (2014)
M. Kritzman, S. Page, D. Turkington, In defense of optimization: the fallacy of 1/n. Financ. Anal. 66, 1–9 (2010)
J. Kuepper, Money Management Using the Kelly Criterion (Investopedia, 2004)
P. Laureti, M. Medo, Y.C. Zhang, Analysis of Kelly-optimal portfolios. Quant. Finance 10, 689–697 (2010)
N.K. Lioudis, Sharpe ratio (Investopedia, 2017)
Q. Liu, On portfolio optimization: How and when do we benefit from high-frequency data? J. Appl. Econom. 24, 560–582 (2009)
A. Loginov, M. Heywood, On the impact of streaming interface heuristics on GP trading agents: an FX benchmarking study, in ACM Genetic and Evolutionary Computation Conference, pp. 1341–1348 (2013)
A. Loginov, M. Heywood, On the utility of trading criteria based retraining in forex markets, in Applications of Evolutionary Computation (EvoFIN), LNCS, 7835, 192–202 (2013)
A. Loginov, G. Wilson, M. Heywood, Better trade exits for foreign exchange currency trading using FXGP, in IEEE Congress on Evolutionary Computation, pp. 2510–2517 (2015)
L.C. MacLean, E.O. Thorp, Y. Zhao, W.T. Ziemba, How does the fortune’s formula-kelly capital growth model perform? J. Portf. Manag. 37, 96–111 (2011)
J. Malek, T.V. Quang, Investing in high frequency data. Bus. Trends 6(3), 21–27 (2016)
V. Manahov, The rise of the machines in commodities markets: new evidence obtained using strongly typed genetic programming. Annu. Oper. Res. 260, 321–352 (2018)
H. Markowitz, Portfolio selection. J. Finance 7, 77–91 (1952)
B. Matthew, B. Jonathan, H. Björn, A. KirilenkoRisk, Return in high frequency trading. J. Financ. Quant. Anal. 82, (2018)
V. Nekrasov, Kelly criterion for multivariate portfolios: a model-free approach. SSRN Electron. J. 10(2139), 1–14 (2013)
M.E.H. Pedersen, Portfolio optimization and Monte Carlo simulation. Hvass Laboratories Report HL-1401, pp. 1–96 (2014)
J. Potvin, P. Soriano, M. Vallee, Generating trading rules on the stock markets with genetic programming. Comput. Oper. Res. 31, 1030–1047 (2004)
W. Poundstone, Fortune’s Formula (Hill and Wang, 2005)
R.T. Rockafellar, S. Uryasev, Optimization of conditional value-at-risk. J. Risk 2, 493–517 (2000)
F. Turcas, F. Dumiter, P. Brezeanu, P. Farcas, S. Coroiu, Practical aspects of portfolio selection and optimization on the capital market. Econ. Res.-Ekonomska Istrazivanja 30, 14–30 (2017)
Z. Yin, A. Brabazon, C. O’Sullivan, P.A. Hamill, A genetic programming approach for delta hedging. Genet. Program Evolvable Mach. 20(1), 67–92 (2018)
F.A. Ziegelmann, B. Borges, J.F. Caldeira, Selection of minimum variance portfolio using intraday data: an empirical comparison among different realized measures for bm&fbovespa data. Braz. Rev. Econom. 35 (2014)
Acknowledgements
Alexander Loginov gratefully acknowledges support from the MITACS Accelerate Scholarship program.
Author information
Authors and Affiliations
Corresponding author
Additional information
Publisher's Note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Area Editor: U.-M. O’Reilly.
Rights and permissions
About this article
Cite this article
Loginov, A., Heywood, M. & Wilson, G. Stock selection heuristics for performing frequent intraday trading with genetic programming. Genet Program Evolvable Mach 22, 35–72 (2021). https://doi.org/10.1007/s10710-020-09390-5
Received:
Revised:
Published:
Issue Date:
DOI: https://doi.org/10.1007/s10710-020-09390-5
Keywords
- Stock
- Trading
- Intraday
- Portfolio