![]() |
|
|||||||
| Suggestions And Feedback New feature suggestions and feedback. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#16 |
|
Senior Member
Join Date: Jan 2012
Location: Austin Texas
Posts: 132
Thanks: 32
Thanked 7 times in 7 posts
|
Again, not my problem if I have a workaround. But missing prints in OnBarUpdate can't possibly be unique to my setup, not if I get those prints when I use OnMarketData.
|
|
|
|
|
|
#17 | |
|
Senior Member
Join Date: Aug 2010
Location: Washington, D.C.
Posts: 1,269
Thanks: 193
Thanked 332 times in 287 posts
|
Quote:
I guess you don't have market replay recording enabled? There have been reports/complaints about market replay becoming slower because of trades "filling up the database". There was a recent post from someone doing thousands of trades a day running out of memory(this may have been you ).I don't have Kinetick, but can't you download one of these stocks that have an issue that day, and run it through market replay with this OnBarUpdate/OnMarketData checker program? If that proves out a difference, then NT Support might have something more to chase down. This could be IB related otherwise. I have TDA... but I'm not sure how I'm going to figure out which out of 200-500 stocks is going haywire easily with missing OnBarUpdate calls.
|
|
|
|
|
|
|
#18 | |
|
Senior Member
Join Date: Aug 2010
Location: Washington, D.C.
Posts: 1,269
Thanks: 193
Thanked 332 times in 287 posts
|
Quote:
Is it more pronounced when the market it *glitchy* for the day? Do you have any filtering enabled in NT? Tools->Options-> Data Tab-> Filter bad ticks 10% off market? I guess that could explain why OnBarUpdate (filtered) and OnMarketData might not be same (assuming OnMarketData doesn't use this filter option).
|
|
|
|
|
|
|
#19 | |
|
Senior Member
Join Date: Aug 2010
Location: Washington, D.C.
Posts: 1,269
Thanks: 193
Thanked 332 times in 287 posts
|
Quote:
OnMarketData - Last was not always equal OnBarUpdate ( Closes[1][0] )... This doesn't explain "dropped" things.. I assumed OnMarketUpdate was called first. THen OnBarUpdate. So I set my local varialbe in OnMarketUpdate and then compared to OnBarUpdate Closes[1][0], and *sometimes* it didn't match. I was careful with BarsInProgress everywhere, as this was an added series in my indicator (BIP=1). With 6E, I multiplied it by *1000 to make sure it wasn't some dumb double error issue. The print looked fine. |
|
|
|
|
|
The following user says thank you to sledge for this post: |
|
|
|
#20 |
|
NinjaTrader Customer Service
Join Date: Dec 2009
Location: Denver, CO, USA
Posts: 6,499
Thanks: 109
Thanked 291 times in 280 posts
|
Hello,
Thanks for the testing. With the NT Core being multi threaded you cannot actually count on OnMarketData() getting called before OnBarUpdate() could be the other way around and also gets more complex when you add a secondary series on which gets fired when. -Brett
Brett
NinjaTrader Customer Service |
|
|
|
|
|
#21 |
|
Senior Member
Join Date: Jan 2012
Location: Austin Texas
Posts: 132
Thanks: 32
Thanked 7 times in 7 posts
|
Hi Sledge/Radical,
I experienced this problem with equities, typically smallish ones (100-200K shares per day). The problem tends to happen when the stock is indecisive (30 seconds between trades) and tanking (15-cent drops on $40 stocks, not enough to trigger the 1% filter I have activated). I don't think that market replay is a valid way to test this. That's probably what Ninja's QA team used to "prove" that everything was alright. When I was experiencing this problem a few months ago, the market was a lot more volatile than it is now, so it might take a little more difficult to reproduce the problem in August - when was the last time you saw a stock be indecisive AND tanking in the last few weeks? When I switched over to OnMarketData, that situation was common, and the problem immediately disappeared. I did not test the two in parallel; instead, I ran a simple program that printed time and price for every print using OnBarUpdate and then quickly modified it to OnMarketData for the same symbol that was experiencing this problem all day long, and then flipped it back and forth a few times. In all instances, I saw dropped prints (compared to my IB screen) on OnBarUpdate and not on OnMarketData. I figured what was the point of testing one NT product vs another? Why not compare each against an independent source? This can only be done with smallish stocks because otherwise there's no way to keep track of them visually. |
|
|
|
|
|
#22 |
|
Senior Member
Join Date: Sep 2008
Posts: 543
Thanks: 80
Thanked 187 times in 131 posts
|
I don't think you've mentioned explicitly in this thread yet, are you using Kinetick or IB through NT? Which are you having this problem with?
|
|
|
|
|
|
#23 |
|
Senior Member
Join Date: Jan 2012
Location: Austin Texas
Posts: 132
Thanks: 32
Thanked 7 times in 7 posts
|
Hi Radical,
I'm using Kinetick as the primary data feed and Interactive Brokers as the broker. The IB screen shows the data from IB, which is usually (except in the situation we're talking about) identical to the data in NinjaTrader. The problem isn't with either feed, but with OnBarUpdate vs. OnMarketData. |
|
|
|
|
|
#24 |
|
Senior Member
Join Date: Sep 2008
Posts: 543
Thanks: 80
Thanked 187 times in 131 posts
|
If you're comparing Kinetick data with IB data, I think it's pretty possible that the difference you're seeing is between the feeds themselves, and has nothing to do with NT. IB data is aggregated, Kinetick is not, and it would be very possible to see the difference if you're watching tick by tick.
|
|
|
|
|
|
#25 |
|
Senior Member
Join Date: Jan 2012
Location: Austin Texas
Posts: 132
Thanks: 32
Thanked 7 times in 7 posts
|
Hi Radical,
I totally agree that that's a possibility (and mentioned it in post #7 of this thread). If I thought it was just a difference between IB and Kinetick, I would have dropped the issue a long time ago and continued using OnBarUpdate. But, the only time I've ever seen a difference between the two feeds is when I was using OnBarUpdate, and never when I've been using OnMarketData, so that implies a difference between OnBarUpdate and OnMarketData, not a difference between IB and Kinetick. |
|
|
|
|
|
#26 |
|
Senior Member
Join Date: Sep 2008
Posts: 543
Thanks: 80
Thanked 187 times in 131 posts
|
Frankly I think that could just be a coincidence though. Seeing that behavior just a handful of times could have many different causes, especially if you weren't recording the data at the time. I just think it's a big waste of time to focus all of your energy on OnMarketUpdate vs OnBarUpdate being the problem when really there are other things that could just as easily be the source of the problem. And given that the IB vs Kinetick difference is a documented, known difference, I would say that is more likely the problem.
|
|
|
|
|
|
#27 |
|
Senior Member
Join Date: Jan 2012
Location: Austin Texas
Posts: 132
Thanks: 32
Thanked 7 times in 7 posts
|
This is probably why the problem has never been addressed. Everybody thinks it works 100% of the time because it works 99% of the time, and there's no incentive to go hunt for problems, and it's comforting for a trader to think that his data is perfect. If I ever run into CPU problems and need to return to OnBarUpdate, I'll run some real tests and present those results. Until then, I'll leave it as a problem for someone else to prove. I just presented the problem and a description of how to test it. It's not my job (or yours, unless you're experiencing bad fills when your stocks are tanking) to prove it. That job belongs to NT's QA department.
|
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Problem with Swing Prints | heyligerb | General Programming | 12 | 11-18-2011 02:08 PM |
| OnMarketData ,Historical prints. | Ramon | Indicator Development | 6 | 06-02-2011 04:39 AM |
| Script Misses Entry at 8:30 Open | RDPoS | Automated Trading | 3 | 01-12-2010 09:08 AM |
| Account Performance misses trades | pmaglio | Miscellaneous Support | 5 | 09-05-2008 06:32 PM |
| Different prints for same value? | Burga1 | General Programming | 1 | 12-05-2007 10:45 PM |