//AddRenko(instrument1, 10, MarketDataType.Last);
//AddRenko(instrument1, 10, MarketDataType.Last);
//AddRenko(instrument1, 10, MarketDataType.Last);
//AddRenko(instrument1, 10, MarketDataType.Last);
then create doubles of these:
double instrument1EMA = EMA(BarsArray[1], 13)[0]
double instrument2EMA = EMA(BarsArray[2], 13)[0]
double instrument3EMA = EMA(BarsArray[3], 13)[0]
double instrument4EMA = EMA(BarsArray[4], 13)[0]
Now what I would like to do is rank each of these instruments based on their EMA and assign a string. I know how to go if instrument1EMA > (instrument2EMA && instrument2EMA && instrument3EMA) etc but this is very cumbersome and time consuming. So is there an easier way to rank things and say something like:
If out of the above list give me the one with the highest EMA then give me the one with second highest EMA etc. I checked the manual but couldn't find anything relevant and my programming skills are "evolving".
Thanks
DJ

Comment