Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Sim trades don't match with plotted bars

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

    Sim trades don't match with plotted bars

    Hi,
    I seem to have a problem. When sim trading equities, I seem to get weired trades such as the following:



    Here is the trade log:




    Can someone please explain to me how the exit can be way off?

    I get data from IQFeed and from their diagnostic app, my data ping test to their servers are showing up as:

    Pinging login.interquote.com [66.112.148.212] with 32 bytes of data:

    Reply from 66.112.148.212: bytes=32 time=110ms TTL=47
    Reply from 66.112.148.212: bytes=32 time=111ms TTL=47
    Reply from 66.112.148.212: bytes=32 time=111ms TTL=47
    Reply from 66.112.148.212: bytes=32 time=110ms TTL=47

    Ping statistics for 66.112.148.212:
    Approximate round trip times in milli-seconds:
    Minimum = 110ms, Maximum = 111ms, Average = 110ms

    Are these ping results too slow?

    The problem could be one of:
    o A HW (slow hardware) - I have Intel(R) Core(TM) i7-6850K CPU @ 3.60GHz, 32GB memory, 1GB NAND SSD
    o SW issue (resource overload - I'm running Ninjatrader 8.0.18.1 64-bit) on my computer
    The DSL connection - I have a 80Mbps connection
    o The IQFeed connection.

    I'm confused as to what the problem could be... Any ideas please?

    Regards,
    iq
    Last edited by iq200; 07-19-2019, 08:19 AM.

    #2
    One more question.....

    Why is the entry split into three separate entries?

    Comment


      #3
      First, let's make sure your PC clock is in sync:
      • Shutdown NinjaTrader
      • Right-click the clock in the lower right corner of your desktop
      • Select Adjust date/time
      • For Windows 10 click 'Additional date, time, & regional settings' -> then click 'Set the time and date'
      • Select the 'Internet Time' tab at the top
      • Set the server to time.nist.gov and then click Update.
      • If the message that appears says successful your PC clock should now be updated.
      • If not, select a different server from the Server: drop-down and try again (repeat until one of the servers is successful)
      After updating the PC clock, please restart NinjaTrader, then right-click the chart and select Reload All Historical Data.

      If the symptom persists, please answer the following:
      • What version of IQFeed Data Manager are you using?
      • If you open a SuperDOM or Time & Sales window and compare that data to your charts current price, are they within a tick or so? Or is there a large price difference between these windows?
      Originally posted by iq200 View Post
      One more question.....

      Why is the entry split into three separate entries?
      Orders fill based on available volume. The simulation engine tries to mimic real life behavior and in this case, there wasn't enough volume to fill your 1000 qty orders in one fill.
      Last edited by NinjaTrader_PatrickG; 07-19-2019, 08:43 AM.

      Comment


        #4
        Hi Patrick,
        Thanks for replying.
        So I just synchronized the clock. It was set to the microsoft server but I have now updated it to the nist.gov server.


        I noticed though that in my Date and Time settings, my Set time automatically was set to off which I have now turned on:


        I believe I am using Version: 6.0.1.1 of IQFeed.

        With regards, to trading, I am using the Basic Entry form and not the Superdom. A while ago I tried to sign up to equities Level 2, and could not get depth more than the best bid/ask. After enquiring, I was told that Superdom could not display equities Level 2 (don't quote me but it was something to that effect), so I unsubcribed from the Level 2 and don't use the Superdom because of this reason.

        Anyway I use Time and Sales and can see good correlation/synch between it and the best bid and ask on the Basic Entry screen. The chart prices also seem to be in synch with the T&S window. I usually use the chart to enter and then use it combined with the PnL to exit so I am sure that I would have got the correct prices but am puzzled as to why there is the d3escrepancy I highlighted above.

        Regards,
        iq

        Comment


          #5
          That's correct. The SuperDOM does not supper level II equities data. You would be able to see level II equities data in the Level II window.

          Please clarify - You're reporting that the misalignment is still present after the clock sync/reload historical data? If so, can you reproduce this symptom? Or does it seem isolated to that one execution?

          Comment


            #6
            Yes. I closed down Ninjatrader 8, adjusted the clock settings as you said and then restarted Ninjatrader. The trade descrepancy marking on the chart was still there.
            I took a few random sim trades and they seem to be OK.
            However I did notice this same problem with the Bank of America (BAC) ticker on Wednesday when they had results:


            The stock was highly active. One thing that could be a factor is that these trades just after the open? There is a lot of trading going on then. Just a thought.

            Comment


              #7
              There is potential that the simulation engine is corrupt. Resetting a simulation account will clear all historical trade data from this account. Please follow the instructions below to reset a simulation account.
              • From the NinjaTrader Control Center window select the Accounts tab
              • Right click on your simulation account and select Edit Account
              • Press the "Reset" button

              Comment


                #8
                Rather than delete the account, can I just add a new account and try with that? Your reply implies this should be the same thing

                Comment


                  #9
                  Yes, that would effectively be the same thing.

                  Comment


                    #10
                    Many thanks for your help Patrick.
                    I’ll try with a new account as I don’t want get rid of my trade history.
                    I’ll report back in case of problems.

                    Comment


                      #11
                      Patrick,
                      regarding the BAC trade I mentioned above, I remembered now that I had really bad issues on the chart. Basically the chart was severely lagging the Level 1 data. However I know the level data was correct as I matched it up to my real brokerage platform.

                      The problem seemed to be on the chart. If I did a manual reload of the data it would mostly catch up but then get out of synch again and start lagging which would get worse and worse as time progressed.

                      i tried restarting Ninjatrader, my computer and even my internet but the problem continued and strangely only for BAC.
                      thanks,
                      iq

                      Comment


                        #12
                        I would do the same test as mentioned earlier when you think your charts may be lagging. What it's starting to sound like you're describe is what we call a 'rendering delay'. Basically, there is so much incoming data and due to the complexity of your workspace/power of your PC, the chart cannot keep up with real- time data.

                        Originally posted by NinjaTrader_PatrickG View Post
                        • If you open a SuperDOM or Time & Sales window and compare that data to your charts current price, are they within a tick or so? Or is there a large price difference between these windows?
                        If you do detect this, we can provide some additional diagnostic and troubleshooting steps to resolve the rendering delay.

                        Comment


                          #13
                          I have been a software engineer and from experience I feel my PC spec is not the latest by any means but it's not so bad that it would be causing Ninjatrader to run slowly as you imply. It feels fast and extremely responsive at all times.

                          So what can I do to reduce this delay, if it is indeed a problem? Less indicators and charts? Can you please elaborate with these steps and diagnostic info so that I 'feed myself' ?
                          Last edited by iq200; 07-19-2019, 02:03 PM.

                          Comment


                            #14
                            Yes, reducing workspace complexity is the best way to improve performance or mitigate sluggishness/unresponsiveness frequency.

                            Providing the steps now is kind of 'putting the cart before the horse', however, I would start by asking you:
                            • How many open workspaces are there?
                            • In those workspaces, how many total charts are there?
                            • In those charts, how many total chart tabs are there?
                            • In all chart tabs, how many total indicators are there?
                            Then, to see what (if any) NinjaScript items may be contributing to the symptoms, please open the NinjaScript Utilization Monitor:
                            • Control Center > New > NinjaScript Output
                            • Right-click within the NinjaScript output window > Select 'NinjaScript Utilization Monitor...
                            • This window will begin to populate with NinjaScript items in order of time spent processing
                            • Let this window populate for at least a few minutes then send me a screenshot of it's contents
                            Also, I have provided a link below to our Help Guide that goes over performance tips:

                            Comment


                              #15
                              That's great Patrick. Extremely useful. Thank-you!
                              I'll run this next week and report back to you as the market is closed now.

                              Comment

                              Latest Posts

                              Collapse

                              Topics Statistics Last Post
                              Started by algospoke, 04-17-2024, 06:40 PM
                              6 responses
                              49 views
                              0 likes
                              Last Post algospoke  
                              Started by arvidvanstaey, Today, 02:19 PM
                              4 responses
                              11 views
                              0 likes
                              Last Post arvidvanstaey  
                              Started by samish18, 04-17-2024, 08:57 AM
                              16 responses
                              61 views
                              0 likes
                              Last Post samish18  
                              Started by jordanq2, Today, 03:10 PM
                              2 responses
                              9 views
                              0 likes
                              Last Post jordanq2  
                              Started by traderqz, Today, 12:06 AM
                              10 responses
                              21 views
                              0 likes
                              Last Post traderqz  
                              Working...
                              X