Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Strategy executes differntly backtest vs live

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

    Strategy executes differntly backtest vs live

    Hi from Oklahoma

    A strategy that performs correctly in backtest is
    not executing correctly in realtime.

    Could there be a simple explanation for this?

    Thanks

    Lynn

    #2
    This link may provide some guidance.

    RayNinjaTrader Customer Service

    Comment


      #3
      Strategy Execution

      Hi Ray

      It is not the difference in fills, it is difference in quantity
      Strategy is designed to execute Long 1a, long 1b, and
      long 1c, and take them off at various tgts.

      Sim execution on live data only executes 1 lot.

      A bit strange

      Lynn

      Comment


        #4
        Have you hardcoded in the quantity to be traded or are you using DefaultQuantity? I believe this setting is modifiable when you are starting the strategy.
        Josh P.NinjaTrader Customer Service

        Comment


          #5
          Strategy executes differntly backtest vs live

          Hello,

          I also encounter the same problem with a double down strategy.In the strategy, I double my positions when price drops furthur from the first entry..etc.

          In backtesting, the results looks normal. , Sell order Qty=Buy order Qty

          But when I test in real-time, the is an error in quantity of order.(see screenshot), Sell order changes when the last Sell order was placed.

          any answer for this difference in backtest and live?
          Last edited by justmake; 05-19-2008, 02:21 AM.

          Comment


            #6
            You will need to debug your strategy with TraceOrders to see what it is doing. From what I can tell I am guessing you may be amending your order which is why it is increasing like that. Another possible area to investigate would be how your two long orders went through and if it has any impact on your exit orders.
            Josh P.NinjaTrader Customer Service

            Comment


              #7
              Strategy executes differntly backtest vs live

              Hello,Josh,

              After seeing Output window, I do see "Amending matching order:Action..."
              in the output which changes the orginal Sell limit order to Wrong QTY.

              Because this problem didn't happen in backtesting, how should I solve this problem? Should I change the method for placing the Sell limit order?

              thanks.
              Attached Files

              Comment


                #8
                For clarification -

                Is this a sell order that was triggered by SetProfitTarget() ?
                RayNinjaTrader Customer Service

                Comment

                Latest Posts

                Collapse

                Topics Statistics Last Post
                Started by Geovanny Suaza, 02-11-2026, 06:32 PM
                0 responses
                633 views
                0 likes
                Last Post Geovanny Suaza  
                Started by Geovanny Suaza, 02-11-2026, 05:51 PM
                0 responses
                364 views
                1 like
                Last Post Geovanny Suaza  
                Started by Mindset, 02-09-2026, 11:44 AM
                0 responses
                105 views
                0 likes
                Last Post Mindset
                by Mindset
                 
                Started by Geovanny Suaza, 02-02-2026, 12:30 PM
                0 responses
                566 views
                1 like
                Last Post Geovanny Suaza  
                Started by RFrosty, 01-28-2026, 06:49 PM
                0 responses
                568 views
                1 like
                Last Post RFrosty
                by RFrosty
                 
                Working...
                X