Performance Metrics

<< Click to Display Table of Contents >>

Navigation:  NinjaScript > Language Reference >

Performance Metrics

Previous page Return to chapter overview Next page

Custom Performance Metrics can be used when generating Trade Performance statistics.

 

Once custom performance metrics are created be sure to enable their usage in Tools > Options > General or else they will not be available in the Strategy Analyzer or Trade Performance windows.

 

In this section

Format()

This method allows you to customize the rendering of the performance value on the Summary grid.

OnAddTrade()

This method is called as each trade is added.

OnCopyTo()

Called as the values of a trade metric are saved.

OnMergePerformanceMetric()

This method is called when the Performance Metric would be aggregated and merged together.

PerformanceUnit

Enumeration defining each type of PerformanceUnit calculated by NinjaTrader. Used to store a value for this performance type in PerformanceMetrics.

Values

The Values array holds an 5 values corresponding to each Cbi.PerformanceUnit.