May 22, 2022

5 2

Rank and Select Strategies by Strategy Metric

This custom analysis sorts and selects x strategies according to the Strategy Metric

The snippet is easily modifiable and can be rewritten to rank strategies by IS/OS, Direction, and Sample Types:


String stratMetric = "MAFEProfitFactor";
int numStrats = 10;
    
for(ResultsGroup strategyRG : databankRG) {

  /// Single or Portfolio? 
  Result mainResult = strategyRG.subResult( strategyRG.getMainResultKey() ); //single results
  //Result mainResult = strategyRG.portfolio(); // portfolio result

 

 

2 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
Emmanuel
Emmanuel
May 23, 2022 4:58 am

Excellent ! Thank you Clonex !!!

Emmanuel
Emmanuel
May 23, 2022 5:16 am

Thanks to your example, I was able to build my code and make my article on how to select better building blocks !!!