General settings

The General section sets the money the strategy trades with and how large its orders are. These values affect every metric in the Strategy Report, so set them to match how you would actually trade.

Initial capital

The amount of money the strategy starts with. Net profit, drawdown, equity curve and all

percentage-based metrics are calculated from this amount.

The currency dropdown next to the field sets the account currency. All results in the Strategy Report are shown in it. If the account currency differs from the currency of the symbol, prices are converted using the exchange rate at the time of each trade.

Example

Initial capital is 10,000 USD. The strategy makes a net profit of 1,500 USD, so the report shows a net profit of +15%.

With a very large initial capital and a fixed order size, returns in percent look tiny.
With a very small one, orders may not be filled because there isn't enough equity.

Default order size

The size of each order when the script doesn't set a quantity itself. The field holds the value, and the dropdown sets its unit:

Quantity A fixed number of contracts, shares, lots or coins in every order.

Currency A fixed amount in the account currency. The number of units is calculated

from the price at the time of the order.

% of equity A percentage of the strategy's current equity: initial capital plus realized and

open profit or loss. Orders grow as the strategy earns and shrink as it loses.

Example

Equity is 10,000 USD, order size is 10% of equity, and the price is 50 USD. The strategy buys 20 shares

(1,000 USD). After equity grows to 12,000 USD, the next order is 1,200 USD.

Keep in mind

If the script passes a quantity directly in its order functions, that quantity is used and this setting is ignored for that order.


Pyramiding

The maximum number of entries the strategy can open in the same direction. It controls whether the strategy can add to a position that is already open.

• 1: one entry per direction. While a long position is open, new long entry signals are ignored.

• More than 1: the strategy can add new entries in the same direction until the limit is reached. Each entry is shown as a separate trade in the List of trades.

Example

Pyramiding is 3. The strategy gets four long signals in a row. It opens three long entries, and the fourth signal is ignored until at least one entry is closed.

Keep in mind

Pyramiding only limits entries in the same direction. An entry in the opposite direction closes or reverses the current position no matter what this value is.