Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Backtest data is different from live data

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

    #61
    I have considered that Matthew.... Do you have any clue why the other computer would trade the same script without issue and this one basically can't execute two positions without overfilling?..... Like every problem in the world, this one HAS an answer..... It's kinda fun to be challenged every now and then right?

    Comment


      #62
      I changed the profit target to 2 ticks like you suggested (to give it more room ) and the overfills continue. I am wondering if it has to do with the NinjaTrader program itself. Maybe I should delete it and try re-installing it? I really need to understand what is happening and I really do not.

      Jamie Hendrix

      Comment


        #63
        I don't believe reinstalling will correct the results you are seeing.

        Can you please clarify who you connect to for data? Are you using the same data provider on both computers?

        Can you please send me the log and trace files from this computer so I can look into this further. Please email these to support[at]ninjatrader[dot]com with Attn: Matthew in the subject line and a reference to this thread.

        In addition, can you please run this strategy on the PC you do not have issues with and send me the files from that PC.

        You will find the log file in the Documents > NinjaTrader 7 > Log folder.
        • The log file will be named ‘log.20120119.txt’

        You will find the trace file in the Documents > NinjaTrader 7 > Trace folder.
        • The trace file will be named ‘trace.20120119.txt’
        MatthewNinjaTrader Product Management

        Comment


          #64
          Same Problem Here

          trading Gary and Jamie,

          I have the same problem regarding discrepancies between the real-time data and the historical data on tick charts. In particular, the Close of each bar often seems to be off.

          Did you guys find a solution to this problem?

          Please let me know if you did (what you did to fix it), I would really appreciate it!

          Thanks,

          Srgtroy

          Comment


            #65
            Srgtroy, could you please let us know which NT7 version (Help >> About to check) and data provider / broker you're using here in your setup?
            BertrandNinjaTrader Customer Service

            Comment


              #66
              I am using the latest version of NT and my data provider is KineTick. My pc clock is continously (every 5 minutes) being synced with the Naval Observatory clock using Dimension 4. I have also tested without running any indicators at all and the discrepancies remain. It's usually with the Close of the bar, sometimes the Open, however, the range is generally correct. The problem is, a lot of even basic indicators like moving averages and rsi work off of the Close rendering them erroneous if not invalid. I love NinjaTrader but if I can't get accurate Tick charts, I may have to start looking elsewhere and I really don't want to.

              Comment


                #67
                Thanks for the reply Srgtroy - how do you exactly determine that the Close used would be 'off'? Do you compare here to another feed or provider?

                There are unfortunately also some expected limitations to be aware of when comparing across feeds and also realtime vs reloaded data from a server source - http://www.ninjatrader.com/support/h..._are_built.htm
                BertrandNinjaTrader Customer Service

                Comment


                  #68
                  I compare the real-time data on my chart with data from the historical server after a reload.

                  If the current method produced a few errors here or there, I could live with it, but a lot of the closes are one tick off, and that adds up and can be important.

                  I have read all the material about how bars are built, but I simply do not understand why its so hard to provide the accurate data.

                  If every tick is natively time-stamped (as its supposed to be with KineTick), I don't see why its so hard to build accurate bars.

                  The only thing left I can think of is that maybe my chart refresh setting (default 0.5) is too slow and somehow affecting the last tick the bars, but I'm not entirely sure how that whole process works. I intend to test that out.

                  I will also setup NT on another computer to see if its my current computer that has an issue, although my internet is pretty fast so I doubt it.

                  Other than that, I suppose I will have to start testing other platforms to see how they do.

                  Comment


                    #69
                    Srgtroy,

                    While your PC may be syncing every 5 minutes wiht the Naval Observatory clock using Dimension 4, the data provider servers are not. We have found better results using the windows method of syncing your clock, and using time.nist.gov servers There should be no reason your PC needs to sync every 5 minutes. Syncing your clock once a day should get your clock in sync with the server.

                    Have you tried comparing the Time & Sales data to your PC clock? What results are you seeing in this case? Please see this post for information on how to do this if you have not yet- http://www.ninjatrader.com/support/f...6&postcount=23

                    There are more factors to play than just the PC clock. There will naturally be a difference in the time it takes a tick to reach your PC, and the time it takes that tick to reach the historical data servers. If having the tick data match from two locations is important to you, you may want to consider using a hosting solution that is closer to the exchange.

                    The chart refresh does not impact the way the data is received or stored. This only changes how fast the chart repaints and displays any updated data.
                    MatthewNinjaTrader Product Management

                    Comment


                      #70
                      Thanks for the reply. time.nist.gov is actually the naval observatory in Washington DC (Naval Institute). I was using the windows method with time.nist.gov to start and only moved to dimension 4 after reading in the help section and on the forum about the importance of syncing the pc clock.

                      Your point about two different locations not getting the data at the exact moment implies that either the data is not natively time-stamped or that the native time stamp is not being used to build the tick bars. Both of these conditions being in effect would remove any disparities between different locations. So, in fact, is it not natively time-stamped? Or is the native time stamp not used when building tick bars?

                      I will compare the Time & Sales data to my pc clock, but again, this implies that tick bars are not being built on native time stamps, which in effect, nullifies the advantages of using a service like Kinetick.

                      Comment


                        #71
                        Originally posted by Srgtroy View Post
                        Your point about two different locations not getting the data at the exact moment implies that either the data is not natively time-stamped or that the native time stamp is not being used to build the tick bars. Both of these conditions being in effect would remove any disparities between different locations. So, in fact, is it not natively time-stamped? Or is the native time stamp not used when building tick bars?
                        If you were using minute or time base intervals, this would be true - however since you're dealing with tick bars, the time stamps will not come into play.

                        For example if you are loading a 100 tick bar chart, the a new bar is created once 100 ticks has been received. What you're seeing is the difference between your PC receiving 100 ticks at close price X and creating a new bar, and the historical data server reviving 100 ticks at closing price of X and creating a new bar.

                        As a result of this, we expect that data will change after loading from the server, especially when dealing with volume based intervals such as tick charts.
                        MatthewNinjaTrader Product Management

                        Comment


                          #72
                          Ok, that's what I thought. The advantage of the Kinetick time-stamping disappears. That's a real shame. I don't understand why it's not implemented.

                          So if time-stamps are not used with tick bars, is there any point in trying to manually match my pc clock with the Time & Sales data?

                          Comment


                            #73
                            I thought about this over the weekend and realized that if time-stamps are not used to build tick bars, the whole pc sync issue goes out the window. If I'm correct, it basically means one of two issues is accounting for the difference in real-time data vs historical data.

                            1. I am not getting the exact same tick data as the historical data, in other words, ticks are being lost in transmission.

                            2. I am getting the same data but NinjaTrader is dropping/not processing all ticks.

                            Is there any way to tell which one it is?

                            Comment


                              #74
                              Srgtroy,

                              You can check to ensure you are receiving the proper ticks by comparing your Time and Sales time stamps to your PC clock. If you're sure the PC clock is in sync, but you notice periods where the data feed is falling behind, this would indicate that your PC is not receiving all the packets in real time, and is likley a result of network lag or dropped packets.

                              You should be able to check the verbose logging on your router for any dropped packets. If you have not, you may also want to connect directly to the modem to eliminate the router as a issue.

                              You should also check with your ISP to ensure they're not doing any sort of packet filtering or data shaping during periods of the day.
                              MatthewNinjaTrader Product Management

                              Comment

                              Latest Posts

                              Collapse

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