CONTRACT

Category: ProBacktest

The CONTRACT instruction in ProBuilder language is used to specify the number of contracts that a trader intends to buy or sell in a trading operation. This instruction is analogous to the SHARES instruction.

Syntax:

x CONTRACT

where x represents the quantity of contracts for the order

Example:

BUY 5 CONTRACTS AT MARKET

This example sets the long order size to 5 contracts.

Additional Information:

  • The CONTRACT instruction is crucial for defining the scale of a trade in terms of contracts, which directly influences the potential profit or loss from the trade.
  • It is important to set this value according to your trading strategy and risk management rules.
  • This instruction does not specify whether the contracts are being bought or sold; it only sets the quantity. The direction of the trade (buy or sell) must be defined in your trading script.
  • CONTRACT can be replaced at any time by SHARECONTRACTSPERPOINTLOT, or LOTS on any type of instrument. In the case of Forex, the specified quantity will be multiplied by the size of a lot.
  • If the quantity is not specified, the default values are:
    • 1 unit for entering a position (e.g., BUY AT MARKET places an order for “1” at the market).
    • The total quantity of the position for exiting (e.g., SELL AT MARKET closes the entire position).

Understanding how to use the CONTRACT instruction effectively can help in managing the trade size and risk, especially in leveraged trading scenarios like futures and options.

Related Instructions:

  • CASH probacktest
  • LOT probacktest
  • SHARES probacktest
  • Logo Logo
    Loading...