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

Why different results on different replay results?

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

    Why different results on different replay results?


    Folks, it's unclear to me why I get different strategy results from different replays setups.

    1) Replay at 1000X, Calculate = OnPriceChange, Result = ($1112.50)
    2) Replay at 500X. Calculate = OnPriceChange, Result = ($1287.50)
    3) Replay at 1000X, Calculate = OnEachTick, Result = $13,675 (I wish!)

    This is running the ES replay for 3/25. I ran this same strategy today on the live market data, and the result was $175.

    Therefor, it's unclear to my why different replay formats are giving different results. Most importantly, how do I set up a replay to make the same results I get when the strategy is running on live market data? Thanks for your help,

    #2
    Hello timmbbo,

    The Calculate setting will change when the logic is called, when, and how often, orders are placed. Orders placed at different times will have different fill prices. More or less orders would results in different performance.

    Are there any values that can change such as a random number generator or logic that can change when orders are placed?

    Are you able to reproduce the behavior using the SampleMACrossover included with NinjaTrader?


    Regarding the speed, I would not expect this to cause differences. Below is a link to a video of running a test on this twice using ES 06-21 on a 1 minute chart, once at 500x and once at 1000x This is using the latest version of NinjaTrader 8, 8.0.24.1. The profit and number of trades is the same.
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      > The Calculate setting will change when the logic is called, when, and how often, orders are placed.

      OK, then how do I set up a simulated backtest which accurately mimics live data? For example, if a strategy gains 5 points during a trading day, then I want my simulated backtest to show that same result. Thanks,

      Comment


        #4
        Hello timmbbo,

        1 tick Intra-bar granularity and Tick Replay will allow the strategy to processes as similar as possible to real-time.

        Citizens of the NinjaTrader Community, A common question we hear from clients is 'why are results from backtest different from real-time or from market replay?'. Live orders are filled on an exchange with a trading partner on an agreed upon price based on market dynamics. Backtest orders are not using these market dynamics.
        Chelsea B.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by warreng86, 11-10-2020, 02:04 PM
        7 responses
        1,360 views
        0 likes
        Last Post NinjaTrader_Manfred  
        Started by Perr0Grande, Today, 08:16 PM
        0 responses
        5 views
        0 likes
        Last Post Perr0Grande  
        Started by elderan, Today, 08:03 PM
        0 responses
        9 views
        0 likes
        Last Post elderan
        by elderan
         
        Started by algospoke, Today, 06:40 PM
        0 responses
        10 views
        0 likes
        Last Post algospoke  
        Started by maybeimnotrader, Today, 05:46 PM
        0 responses
        14 views
        0 likes
        Last Post maybeimnotrader  
        Working...
        X