Analysis of the impact of parameter tuning in stock trading strategies
Abstract
Trading heuristics are very useful techniques for maximizing profits in the stock market. For better performance, it is necessary to specialize the parameter values of such models. This paper aims to discuss the impact of applying tuners on the parameter adjustment of asset buying and selling heuristics. For this, in a case study, four trading techniques were experimented with and compared regarding their respective returns, when comparing the adoption of a manual configuration with two meta-optimizers, a Genetic Algorithm and I-Race. By selecting financial return as the quality criterion, parameter tuning was done using asset price data from Ibovespa from 2012 to 2014. The validation of the return of each stock buying and selling model was calculated between 2015 and 2021. The results indicate that tuners are statistically capable of improving performance compared to manual configuration.
References
Balvers, R. J. and Wu, Y. (2006). Momentum and mean reversion across national equity markets. Journal of Empirical Finance, 13(1):24–48.
Barboza, F., Garruti, D. V. T., and Silva, M. F. (2021). Previsões de tendência no brasil: uma aplicação de inteligência artificial. Congresso UFU de Contabilidade.
Birattari, M., Stützle, T., Paquete, L., Varrentrapp, K., et al. (2002). A racing algorithm for configuring metaheuristics. In Gecco, volume 2. Citeseer.
Blank, J. and Deb, K. (2022). pymoo: Multi-objective optimization in python. https://pymoo.org/index.html. Accessed: 2023-03-05.
Derrac, J., García, S., Molina, D., and Herrera, F. (2011). A practical tutorial on the use of nonparametric statistical tests as a methodology for comparing evolutionary and swarm intelligence algorithms. Swarm and Evolutionary Computation, 1(1):3–18.
Gendreau, M., Potvin, J.-Y., et al. (2010). Handbook of metaheuristics, volume 2. Springer.
Gropp, J. (2004). Mean reversion of industry stock returns in the us, 1926–1998. Journal of Empirical Finance, 11(4):537–551.
Gunasekarage, A. and Power, D. M. (2001). The profitability of moving average trading rules in south asian stock markets. Emerging markets review, 2(1):17–33.
Hilpisch, Y. (2021). Python for Algorithmic Trading. O’Reilly.
Hooker, J. N. et al. (2012). Integrated methods for optimization, volume 170. Springer.
Hu, Y., Liu, K., Zhang, X., Su, L., Ngai, E., and Liu, M. (2015). Application of evolutionary computation for rule discovery in stock algorithmic trading: A literature review. Applied Soft Computing, 36:534–551.
Huang, C., Li, Y., and Yao, X. (2019). A survey of automatic parameter tuning methods for metaheuristics. IEEE transactions on evolutionary computation, 24(2):201–216.
Koijen, R. S., Rodriguez, J. C., and Sbuelz, A. (2009). Momentum and mean reversion in strategic asset allocation. Management science, 55(7):1199–1213.
Kramer, O. and Kramer, O. (2017). Genetic algorithms. Springer.
López-Ibáñez, M., Cáceres, L. P., Dubois-Lacoste, J., Stützle, T. G., and Birattari, M. (2016). The irace package: User guide. IRIDIA, Institut de Recherches Interdisciplinaires et de Développements en . . . .
López-Ibáñez, M., Dubois-Lacoste, J., Cáceres, L. P., Birattari, M., and Stützle, T. (2016). The irace package: Iterated racing for automatic algorithm configuration. Operations Research Perspectives, 3:43–58.
Machado, A. E., Viana, R. T., Dalip, D. H., Cardoso, R. T., and da Cruz, A. (2022). Avaliação de estratégias de operação em swing trade baseadas em aprendizado de máquina. In Anais do I Brazilian Workshop on Artificial Intelligence in Finance, pages 69–80. SBC.
Murphy, J. J. (1999). Technical analysis of the financial markets: A comprehensive guide to trading methods and applications. Penguin.
Nascimento, O. S., Santos, F. G., and Ferreira, K. H. A. (2022). Previsão de preços de ações utilizando inteligência artificial. In Anais do I Brazilian Workshop on Artificial Intelligence in Finance, pages 37–47. SBC.
Nuti, G., Mirghaemi, M., Treleaven, P., and Yingsaeree, C. (2011). Algorithmic trading. Computer, 44(11):61–69.
Okunev, J. and White, D. (2003). Do momentum-based strategies still work in foreign currency markets? Journal of Financial and Quantitative Analysis, 38(2):425–447.
Osaba, E., Villar-Rodriguez, E., Del Ser, J., Nebro, A. J., Molina, D., LaTorre, A., Suganthan, P. N., Coello Coello, C. A., and Herrera, F. (2021). A tutorial on the design, experimentation and application of metaheuristic algorithms to real-world optimization problems. Swarm and Evolutionary Computation, 64:100888.
