Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Trailing stop?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Trailing stop?

    I am trying to place a trailing stop in the strategy wizard. I have a 6 tick profit target but once the current price moves 5 ticks above(for Long) entry or 5 ticks below (for short) entry, move the the stop up to 4 ticks above entry price . Heres how I have it in the wizard. BUT... its not working...any ideas what I have wrong? Thanks

    SetProfitTarget("",CalculationMode,Ticks,6)
    SetTrailStop("4",CalculationMode,Ticks,5,False)

    #2
    sdt929, your trailing stop is not picked up as the FromEntrySignal name field contains the incorrect entry 4 - here you would either put the name of your entry signal in or just leave empty like you did it for the ProfitTarget above.

    Comment


      #3
      Both?

      So, would I set it in the wizard to have a hard stop (5 ticks) and a trailing stop (4 ticks above entry)? If market moves in my direction I just want to at least lock in 4 ticks profit.

      Comment


        #4
        Hello sdt929,

        You can't combine both SetStopLoss() with SetTrailStop(). It will use the stop loss only.

        Trail stop in a NinjaScript strategy does not work the same as an ATM strategy. There is no field for profit trigger like an ATM.

        Trailstop places a stop order at the last traded price +/- the specified tick or percent. Mode price does not make sense in trail stop context.

        Example:
        Long Position enters at 1000
        Trail stop defined at 10 ticks is placed initially at 990.
        If market raises to 1010, stop loss is moved to 1000.

        Adjustments to the price are made either on every tick or on bar close depending on CalculateOnBarClose setting. It will not retreat in other direction - in example above, it stays at 1000 if trading goes from 1010 to 1000.
        Ryan M.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Geovanny Suaza, 02-11-2026, 06:32 PM
        0 responses
        576 views
        0 likes
        Last Post Geovanny Suaza  
        Started by Geovanny Suaza, 02-11-2026, 05:51 PM
        0 responses
        334 views
        1 like
        Last Post Geovanny Suaza  
        Started by Mindset, 02-09-2026, 11:44 AM
        0 responses
        101 views
        0 likes
        Last Post Mindset
        by Mindset
         
        Started by Geovanny Suaza, 02-02-2026, 12:30 PM
        0 responses
        553 views
        1 like
        Last Post Geovanny Suaza  
        Started by RFrosty, 01-28-2026, 06:49 PM
        0 responses
        551 views
        1 like
        Last Post RFrosty
        by RFrosty
         
        Working...
        X