# Instrument statistics¶

## Definitions¶

The number of trades which have been done between and .
The position closing price at moment : .
The number of closed positions during the life of a strategy.
The sum of profit or loss of the strategy: .
The total sum of all closed positions with positive : .
The total sum of all closed positions with negative : .
The number of closed positions with positive value: .
The number of closed positions with negative value: .
The price with which a trade was done at moment , by the strategy.
The quantity that strategy buys or sells at the moment .
In each step of a strategy can either buying or selling an asset. The value of describes strategy’s position at moment .
The maximum price with which a trade was done by the strategy up to the moment : .
The minimum price with which a trade was done by the strategy up to the moment : .
The best possible trade at moment : .
The sum of the best possible trades: .
The worst trade to be done at moment : .
The sum of the worst possible trades: .

## Simple statistics¶

Test Period From
This is the time when the first trade was done by the strategy, its symbol is .
Test Period Until
This is the time when the last trade was done by the strategy, its symbol is .
This is the best position closing price, it is defined as follows

This is the worst position closing price, it is defined as follows

It is the average profit or loss of all the transactions made by the strategy. It is defined as follows

It is the average price of closed position with , it is defined as follows:

It is the average price of closed position with , it is defined as follows:

Ratio Average Win Average Loss
It is the ratio between the expected profitable trade and expected unprofitable trade. It is defined as follows:

Average maximum favorable excursion
It is the average of best possible trades. It is defined as follows

It is the average of the worst trades. It is defined as follows:

It is the difference between the maximum excursion average and the average trade. It is defined as follows:

Total number of all trades done by the strategy is equal to .
Total number of short trades done by the strategy. It is defined as follows:

Total number of long trades done by the strategy. It is defined as follows:

It is a number of closed positions which are profitable.

It is a number of closed positions which are unprofitable.

It it the ratio, expressed in percents, between the number of winning trades and all trades. It is defined as follows:

## Profit/loss statistics¶

Gross Loss
It is a sum of all unprofitable closed positions. It is defined as follows:

Gross Profit
It is a sum of all profitable closed positions. It is defined as follows:

PnL%
It is the precentage change in the portfolio value, when the strategy is finished. It is defined as follows:

Profit Factor
It is a ratio between the ratio between total profit of all closed positions and the total loss of all closed positions. It is defined as follows:

Net Profit
It is the difference between the gross profit and the gross loss. It is defined as follows:

Last Price
It is the last market price of an instrument when the strategy is done. Its symbol is .
Closed PnL
Overall profit reduced by loss of all closed positions. Expresses actual accounted revenue of strategy at some moment . Calculated basing on all actual transactions (the volume and price of transaction are known). Denoted as .
Estimated PnL
Theoretical profit reduced by loss concerning only open positions, estimated basing on current market price and volume of instruments kept in strategy’s portfolio. Denoted as .
Total PnL
This statistic is defined as a sum of the two previous statistics.