Let's say I've created what amounts to a global universe and then divided it into 12 sector sub-universes, and I have optimized a rankingsystem to each sector using a Genetic Algorithm and CMA-ES.
Is it possible to achieve a solution in the simulation where, when it needs to select a stock from a sector, it automatically chooses the optimized ranking system as well? Or are there other methods for how I can utilize this sector optimization that is located in several different ranking systems?
There's a limit to the number of different ranking systems you can use in one simulation (not sure what the limit is). But the language in the buy rules is easy: (Sector=Financial) * Rating("[name of ranking system]") + (Sector=Tech) * Rating ("[name of ranking system]") etc and then specify a threshold (e.g. > 99.5). You can also use RatingPos if you prefer and then your threshold would be < 6 or whatever.
Thanks for sharing but it does not work for me or I did it wrong.
If we want to select top 10 stocks from each sector (tech and financials) based on two separate ranking systems, then this formula does not work for me:
Yes, I apologize, I did get it wrong. You have to use Rating, not RatingPos. And it's not going to reproduce the exact same ranking as you would have gotten if you'd used it on the sector alone. The best way to deal with that is to change all the nodes in your sector-specific ranking systems to use "sector" instead of "universe." I use FOrder in combination with RankPos all the time; are you sure it doesn't work with RatingPos? Did you use nested quotations?