robertmartin8 / PyPortfolioOpt

Financial portfolio optimisation in python, including classical efficient frontier, Black-Litterman, Hierarchical Risk Parity
https://pyportfolioopt.readthedocs.io/
MIT License
4.28k stars 930 forks source link

Optimization based on other parameters than risk and return #400

Closed emillaursen95 closed 2 years ago

emillaursen95 commented 2 years ago

Would I be able to include other parameters in the portfolio optimization process than risk and return characteristics? I have a case when I want to construct a portfolio of 50 stocks from an index based on parameters such as ESG scores and valuation metrics. I am using a z-score to account for all of the parameters that I want to base the decision on. The objective is to maximize the Sharpe ratio while being constrained by a maximum tracking error relative to the index. My primary issue is how I can use the z-score as the main decision variable while not exceeding a fixed tracking error and keeping the number of assets at around 50 assets.

I hope that my question is understood - thanks!

robertmartin8 commented 2 years ago

Hi Emil,

That's definitely possible – let me know if the FAQs clarify it for you. You should be able to combine the "constraining a score" and "tracking error" to solve your problem.

Cheers, Robert

emillaursen95 commented 2 years ago

Great, thank you, Robert! Your package is extremely useful.

robertmartin8 commented 2 years ago

Cheers!

Feel free to reopen if you've got any follow-up Qs.