Skip to main content

Conditions

What are Conditions?​

In the Strategy Builder, conditions define the logic for executing trades.
Each condition is an "IF" statement that is evaluated when a candle closes (based on the selected timeframe).

If a condition is satisfied, the linked action will be executed in sequence.

πŸ“Œ Learn more about timeframes here.
πŸ“Œ Learn more about actions here.


How Conditions Work​

  1. Conditions are checked sequentially at every candle close.
  2. If a condition is met, the linked action will execute as per its defined sequence.
  3. Multiple conditions can be added and linked to different actions.

Understanding Condition Identifiers​

1. Condition ID​

Each condition has a unique Condition ID, which is auto-generated by the system.
This is used internally to reference conditions in the strategy code.

2. Condition Name​

  • The Condition Name is a user-defined label for easy reference.
  • It helps users understand the condition’s logic without needing to open the condition editor.
  • Example: Naming a condition as "RSI Below 30" makes it easier to recognize its purpose.
tip

Best Practice:
Use descriptive Condition Names to make strategies easier to read and debug.


Types of Conditions​

There are two main types of conditions:

1. Entry Condition​

Entry conditions initiate trades based on specific market conditions and are primarily checked to enter new trades.

Configurable Options for Entry Conditions​

  • Max Entries

    • Defines how many times the condition should trigger per day.
    • Even if the strategy type is Positional, Max Entries is still limited to daily occurrences.
    • Default: ∞ (Unlimited).
  • Check if any position is open

    • By default, conditions are only checked if there are no open positions.
    • If set to True, the condition will be evaluated even when a position is open.
  • Check if any trigger is open

    • A trigger refers to an order in Wait & Trade mode.
    • By default, conditions are checked only when there are no open triggers.
    • If set to True, the condition will still be checked even if an order is waiting in Wait & Trade mode.
tip

How to Stop Triggers?
In actions, users can use the "Stop all Wait Trade triggers" option to stop all pending orders.


2. Exit Condition​

Exit conditions close positions when certain criteria are met.

  • Exit conditions are only checked when there is an open position.
  • Currently, there are no additional configurations for exit conditions.
warning

Exit conditions will not be checked if no positions are open.


Next Steps​

βœ… Add Conditions to your strategy
βœ… Link Conditions to Actions for trade execution
βœ… Test your conditions using Backtesting