Combining Clustering and Genetic Algorithms for Portfolio Optimization: A Case Study with B3 Companies - Alonso, Edsson Israel Andonaegui; Delgado, Karina Valdivia; Santos, Francisco Carlos B. dos (Anais da Brazilian Conference on Intelligent Systems (BRACIS); 2024: Anais da XXXIV Brazilian Conference on Intelligent Systems, 2024)
Portfolio optimization has been addressed by optimization algorithms and due to the numerous local maxima, genetic algorithms have shown promise. Recent studies use these algorithms to optimize stock portfolios, whether as a multi-objective problem that maximize return and minimize risk or just as one objective problem, such as maximizing the Sharpe Ratio. In order to adapt these algorithms to the financial market, a new approach was developed that includes penalty and cardinality constraints. This study proposes an algorithm with two models of clustering of B3 companies with penalties and cardinality constraints. One model uses the clustering of companies by economic sector and the other model uses the clustering generated by the Kmeans-DTW time series clustering technique. Then the algorithm selects one asset per cluster of companies with the aim of diversifying the portfolio and reducing the correlation between assets, thus reducing the risk. Finally, the generated portfolios went through an optimization stage using a memetic genetic algorithm, which finds the best possible distribution that maximizes return and reduces risk.