Can stop-loss behavior change over time within the same trade?

Yes, in MagicTradeBot, stop-loss behavior can change over time, but this depends on how you configure Threshold Rules for a trade.


๐Ÿง  How It Works

  1. Single Rule:

    • If only one stop-loss rule is set for a trade, the stop-loss behavior is fixed based on that rule.
    • No adjustments occur over time; the trade will only close if that single threshold is met.
  2. Multiple Rules:

    • By defining multiple time-based Threshold Rules, the stop-loss can adapt as the trade ages.
    • Each rule becomes active when the trade reaches the specified age in minutes (Minutes parameter).
    • Later rules can adjust:

      • Loss thresholds (ThresholdPer)
      • Dynamic SL behavior (EnableDynamicSL / DynamicSLPercentage)
      • Profit-close conditions (CloseIfProfit)

๐Ÿ”„ Example Configuration

ThresholdRules:
  - Minutes: 10
    ThresholdPer: -20
    RuleName: "Stop Loss - Short"
    EnableDynamicSL: false
    CloseIfLoss: true

  - Minutes: 20
    ThresholdPer: -10
    RuleName: "Stop Loss - Short"
    EnableDynamicSL: false
    CloseIfLoss: true

  - Minutes: 60
    ThresholdPer: 0.0
    RuleName: "Stop Loss - Short"
    EnableDynamicSL: true
    DynamicSLPercentage: 3
    CloseIfProfit: true

Behavior over time:

  • 0โ€“10 minutes: Only Rule 1 is active โ†’ triggers if loss > 20%
  • 10โ€“20 minutes: Rule 2 overrides โ†’ now triggers if loss > 10%
  • After 60 minutes: Rule 3 activates โ†’ can close trade if profit โ‰ฅ 0% and dynamic stop-loss begins tracking favorable movement

๐Ÿ“Œ Key Points

  • Stop-loss can change over time only if multiple rules are configured
  • Time-based rules allow gradual adaptation to trade progress and market behavior
  • Dynamic SL in later rules can trail profits after initial thresholds have passed
  • Single-rule configuration results in static stop-loss behavior

In short, stop-loss behavior is flexible when using multiple rules, allowing the bot to tighten or relax exit thresholds as the trade evolves, mimicking a professional traderโ€™s decision-making process.


๐Ÿ“Ž Related Topics