I subscribe to Norgate premium, and I’d appreciate some general hints or a link on creating an AmiBroker formula which allows me to loop through each sector/industry to find the “best performing” sector/industry, and then to load its stocks to perform subsequent analyses. I could not seem to find any online material on whether it is even practical with AmiBroker. Thank you.
The Amibroker knowledge base covers the process in this link: https://www.amibroker.com/kb/2016/01/30/separate-ranks-for-categories-that-can-be-used-in-backtesting/
In the example there it uses:
Category = SectorID();
However, as an alternative Norgate also has more detailed sectors stored as GICS IDs. So if you want to categorise at the lowest industry group level you would use:
Category = GicsID(0);
Or you can categorise at the highest sector level by using the first two characters of the GICS ID:
Category = StrLeft(GicsID(0), 2);
The GICS classifications can be found in the Symbol search tree.
And the Symbol Information shows which sector the stock belongs to:
Thank you so much for your quick and detailed response. I’ll be spending time this weekend digesting the information, and will update when that is done.
@RobertJay If you are looking for Norgate’s various methods of identification you can see this post on this forum,
But I think the discussions in these threads on the old forum will help you with the ranking of Sector followed by ranking by Stock,
After reading through those posts and codes you should be well on your way.
Thank you very much… that’s very helpful.