Backtesting and Optimization

Performance Characteristics

Performance characteristics are the various factors that can be calculated for a list of trades. The trades can be generated by a strategy in real-time or based on a backtest.
The following are available:
  • all trades
  • all long trades
  • all short trades
  • all winning trades
  • all losing trades
The individual factors are:
AvgEtd The average drawdown at the end of a trade <TradeCollection>.TradesPerformance.<TradesPerformanceValues>.AvgEtd
1
Print("Average ETD of all trades is: " + Performance.AllTrades.TradesPerformance.Currency.AvgEtd);
Copied!
AvgMae Average maximum adverse excursion <TradeCollection>.TradesPerformance.<TradesPerformanceValues>.AvgMae
1
Print("Average MAE of all trades is: " + Performance.AllTrades.TradesPerformance.Currency.AvgMae);
Copied!
AvgMfe Average maximum favorable excursion <TradeCollection>.TradesPerformance.<TradesPerformanceValues>.AvgMfe
1
Print("Average MFE of all trades is: " + Performance.AllTrades.TradesPerformance.Currency.AvgMfe);
Copied!
AvgProfit Average profit for all trades <TradeCollection>.TradesPerformance.<TradesPerformanceValues>.AvgProfit
1
Print("Average profit of all trades is: " + Performance.AllTrades.TradesPerformance.Currency.AvgProfit);
Copied!
CumProfit The cumulative winnings over all trades <TradeCollection>.TradesPerformance.<TradesPerformanceValues>.CumProfit
1
Print("Average cumulative profit of all trades is: " + Performance.AllTrades.TradesPerformance.Currency.CumProfit);
Copied!
DrawDown The drawdown for all trades <TradeCollection>.TradesPerformance.<TradesPerformanceValues>.DrawDow
1
Print("Drawdown of all trades is: " + Performance.AllTrades.TradesPerformance.Currency.DrawDown);
Copied!
LargestLoser The largest losing trade <TradeCollection>.TradesPerformance.<TradesPerformanceValues>.LargestLoser
1
Print("Largest loss of all trades is: " + Performance.AllTrades.TradesPerformance.Currency.LargestLoser);
Copied!
LargestWinner The largest winning trade <TradeCollection>.TradesPerformance.<TradesPerformanceValues>.LargestWinner
1
Print("Largest win of all trades is: " + Performance.AllTrades.TradesPerformance.Currency.LargestWinner);
Copied!
ProfitPerMonth The total performance (wins/losses) for the month (also in percent) <TradeCollection>.TradesPerformance.<TradesPerformanceValues>.ProfitPerMonth
1
Print("Profit per month of all trades is: " + Performance.AllTrades.TradesPerformance.Currency.ProfitPerMonth);
Copied!
StdDev The standard deviation for the wins/losses. With this, you are able to identify outliers. The smaller the standard deviation, the higher the expectation of winnings.
All factors are double values.
Copy link