Closed ghost closed 4 years ago
Hi @krisutopian,
As far as I'm aware everything should be working for max sharpe, as of v1.2.3. However, I'm not exactly clear what your code sample is trying to achieve.
You may find the cookbook recipe helpful.
Let me know if you have any further questions!
Robert
Thanks. The cookbook is really helpful! I think I manage to do some optimization from the cookbook. Currently, I am trying to run a monthly basis of optimization. 1 year of pricing data, I will try to run MVO Optimization every month. Is there any example for this?
I don't have an example of that built-in, but you should be able to write a quick for-loop to get it done. If you provide more details with what exactly you're trying to achieve, I'll try to give more concrete suggestions
Robert
Hi Robert,
I try to optimize 700 securities with sector constraint and individual constraint. it works for min_variance and efficient risk. however, it does not work for max_sharpe. Any ideas?
Thank you!
That sounds like an issue with the solvers, since your optimisation problem is quite big. As of v1.2.3, you can change the solver. It's possible that one of the other solvers might be able to:
ef = EfficientFrontier(mu, S)
ef.solver = "ECOS"
ef.max_sharpe()
Supported solvers are listed here.
Cheers, Robert
Hi Robert, this is part of my code I write to optimize 700 Securities. I add sector constraint and loop through my benchmark weight to set individual weight in the securities cannot more than 10% of benchmark weight. it seems working well. However, I have a few questions.
Does the constraint now work as well in max sharpe ratio? If there is a new version of the module, can you share the code to update latest module? Thank you!