IMO, if you want raw speed and extreme flexibility with advanced ranking features in your code, for stock-based strategies, I suggest AmiBroker.
Its Formula Language (AFL) it is very powerful but, in general, the learning curve is considered steeper than that of many of its competitors'. A big...