Portfolio composition optimizer

2025-02-01

Project repository

This was a quick project I wrote for myself after reading Finansowa Forteca by Marcin Iwuć, a book on personal finances and basic financial literacy. In his book he performs historical analysis of his portfolio composition, showing the cummulative returns across different timeframes, setting the analysis starting point at different influential events. This is basically what this tool was built for, you can add different financial instruments, either from files, pull them from Yahoo Finance or just define them programatically in Python. I thought it would be interesting to hook it up to an optimization framework, too see the front of optimal solutions given a set of optimization objectives.

Fig.1 - Results for a simple portfolio with 4 assets for the 1995 - 2025 period. Composition optimized to minimize volatility and maximize return.