Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

Set methods & Multitimeframe

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

    Set methods & Multitimeframe

    Hello,

    in a multi-timeframe strategy, the SetTrailStop method does not behave correctly with submitted orders from the non-primary serie. For instance, trailstop orders are canceled at the end of the bar.

    I searched the forum and I found this:


    I need to confirm if it is true. In which case it would be appropriate to add a warning in the help about Set methods.

    Thanks

    #2
    Hello cls71,

    Thank you for your post.

    This is true on historical data and in backtesting. For backtesting you would need to use Exit methods with the appropriate barsInProgress index.

    Comment


      #3
      Originally posted by NinjaTrader_PatrickH View Post
      Hello cls71,

      Thank you for your post.

      This is true on historical data and in backtesting. For backtesting you would need to use Exit methods with the appropriate barsInProgress index.

      Thanks Patrick,

      however this issue is happening in Market Replay (it is real time i think)

      Comment


        #4
        Hello cls71,

        Thank you for your response.

        If the Stop Loss is cancelling after one bar in realtime or Market Replay what you are seeing is not expected based simply on using a multiple time frame strategy.

        Please provide the strategy you are testing on your end in your reply. You can attach your strategy to your response by going to File > Utilities > Export NinjaScript > Export selected source files > select your strategy > select the right arrow > Export. The file will be located under (My) Documents\NinjaTrader 7\bin\Custom\ExportNinjaScript.

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by helpwanted, Today, 03:06 AM
        1 response
        14 views
        0 likes
        Last Post sarafuenonly123  
        Started by Brevo, Today, 01:45 AM
        0 responses
        11 views
        0 likes
        Last Post Brevo
        by Brevo
         
        Started by aussugardefender, Today, 01:07 AM
        0 responses
        6 views
        0 likes
        Last Post aussugardefender  
        Started by pvincent, 06-23-2022, 12:53 PM
        14 responses
        244 views
        0 likes
        Last Post Nyman
        by Nyman
         
        Started by TraderG23, 12-08-2023, 07:56 AM
        9 responses
        387 views
        1 like
        Last Post Gavini
        by Gavini
         
        Working...
        X