NeedForTrade Documentation

MaxPosition Class

Lets get maximum opened position.


MaxPositionProfit members:


    // Properties
    int this[int positionAgo] // returns maximum opened position including positionAgo entry

    // positionAgo is counted as follows: 
    // MaxPosition[0] - maximum opened position including current position, 
    // MaxPosition[1] - maximum opened position that was on previous position and so on.

MaxPosition[positionAgo] returns 0 there is no entry with specified positionAgo index.

Example: max_position = MaxPosition[0];