NexusFi: Find Your Edge


Home Menu

 





Ninja Trader Custom Order Book - 1LDom - Source Code


Discussion in NinjaTrader

Updated
      Top Posters
    1. looks_one 1LotTrader with 120 posts (318 thanks)
    2. looks_two Silvester17 with 27 posts (74 thanks)
    3. looks_3 Zondor with 17 posts (28 thanks)
    4. looks_4 philipp with 14 posts (7 thanks)
      Best Posters
    1. looks_one aligator with 3 thanks per post
    2. looks_two 1LotTrader with 2.7 thanks per post
    3. looks_3 Silvester17 with 2.7 thanks per post
    4. looks_4 Zondor with 1.6 thanks per post
    1. trending_up 175,626 views
    2. thumb_up 598 thanks given
    3. group 70 followers
    1. forum 356 posts
    2. attach_file 80 attachments




 
Search this Thread

Ninja Trader Custom Order Book - 1LDom - Source Code

  #311 (permalink)
 
1LotTrader's Avatar
 1LotTrader 
Douglas, United Kingdom
 
Experience: Advanced
Platform: Custom
Trading: Bund
Posts: 181 since Jun 2009
Thanks Given: 206
Thanks Received: 445


futuretrader View Post
Thanks 1Lot. I think the bit at the end about reading the reactions of other players is crucial to reading the order book / order flow. Wyckoff: "This study of responses is one of the most valuable in the Tape Reader’s education. It is an almost unerring guide to the technical position of the market."

There was a nice example in ES yesterday with the orders stacked up at exactly the price that became the high of the day.

Speaking of which, does anyone have any suggestions for an algo for iceberg detection? I've tried (contracts offered > original contracts offered + n), but that flags all additions, not just icebergs.

Never tried it myself but I would start by recording the sequence of the refresh and then analysing it for a consistent timing pattern. It would be much more complex I believe than a simple formulae. Most likely you would need to look into pattern analysis or scanning of some type. Once you have a set of criteria you leave the machine to do the work and watch the days play. The problems I foresee is different people will be using different refresh algo's and you have no way of knowing who's who in order to try and identify any consistent patterns.

Secondly the refresh rate patterns. If it was me anyway and I was looking to chuck a couple of thousand into the market I would be dam sure to scramble the order placement sequence in terms of time. You are essentially getting into algo wars here. I haven't delved too deeply into this myself but I would be interested to hear other comments if anyone has anything to share.

1Lot

Follow me on Twitter Started this thread Reply With Quote
Thanked by:

Can you help answer these questions
from other members on NexusFi?
How to apply profiles
Traders Hideout
ZombieSqueeze
Platforms and Indicators
Better Renko Gaps
The Elite Circle
REcommedations for programming help
Sierra Chart
Exit Strategy
NinjaTrader
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Spoo-nalysis ES e-mini futures S&P 500
33 thanks
Just another trading journal: PA, Wyckoff & Trends
28 thanks
Tao te Trade: way of the WLD
24 thanks
Bigger Wins or Fewer Losses?
23 thanks
GFIs1 1 DAX trade per day journal
21 thanks
  #312 (permalink)
 
DavidHP's Avatar
 DavidHP 
Isla Mujeres, MX
Legendary Market Wizard
 
Experience: Advanced
Platform: NinjaTrader
Broker: Ninjatrader / Optimus Futures / AmpFutures
Trading: ES / 6E / 6B / CL
Frequency: Every few days
Duration: Minutes
Posts: 1,611 since Aug 2009
Thanks Given: 11,341
Thanks Received: 2,744


futuretrader View Post
Speaking of which, does anyone have any suggestions for an algo for iceberg detection? I've tried (contracts offered > original contracts offered + n), but that flags all additions, not just icebergs.

Maybe one issue is that Iceberg orders will usually manifest themselves on what most traders view as the wrong side of the bid/ask. (i.e. if there is an Iceberg seller, orders will continually hit the Ask and the DOM will show little size change as the Iceberg absorbs the trades.)

T&S window shows lots of trades at the Ask indicating buying pressure to make the price rise.
But each time the orders hit the Ask, the size is refreshed and the price does not move.
Most traders would view the large buy side pressure as a reason to buy that level.

But the Iceberg trader is refreshing the orders and not allowing the price to rise.
The result is seen when the buyers are exhausted and the price moves down.
At that point the Iceberg seller will start hitting the Bid and pushing the price further down.
The end result is the buyers into the Iceberg have their stops hit and further selling (stop outs) push even lower.

Rejoice in the Thunderstorms of Life . . .
Knowing it's not about Clouds or Wind. . .
But Learning to Dance in the Rain ! ! !
Follow me on Twitter Reply With Quote
  #313 (permalink)
 
1LotTrader's Avatar
 1LotTrader 
Douglas, United Kingdom
 
Experience: Advanced
Platform: Custom
Trading: Bund
Posts: 181 since Jun 2009
Thanks Given: 206
Thanks Received: 445


I was lying in bed thinking about this IceBerg thing again last night, call me crazy but something else occurred to me. I was thinking through the problem of how I would go about it algorithmically. So another couple of issues came to mind which I hadn't thought of but first lets lay out the basics.

So if we are looking for refresh rate patterns right, we need to record each and every change of bid or ask and then time stamp each and every one of them. So we would end up with a sequence of say.

258 -> 300 -> 250 -> 385 -> 290 -> 270 : Just an example so in this case we have trades going through or orders being pulled and then we have the bid offer being refreshed. So we would want to filter only the adds and forget the others for now.

So:

(258 - 300 ) 42 (300 - 250) no add (250 - 385) 135 (385 - 290) no add (290 - 270) no add

Right essentially we have had the bid/offer charged up twice. 42 added at one point and 135 added at another point. So lets make the example a little more complex, lets say we have a string of quick recharges. Typical of ES. Ignore trades and pulls. Just straight as in above but only a long line of adds/refreshes.

[10,15,20,10,18,20,30,35,10]

So alone they mean nothing. However if we time stamp each and everyone down to the millisecond and then calculate the time interval. We may have something to work with.

[0.002,0.020,0.060,0.002,0.002,0.002,0.002,0.002,0.002]

So in above timing pattern my thought would be that robots or algos being mechanical they would typically generate some sort of consistent timing pattern. One could say potentially we have a pattern match on the last 6 refreshes.

Granted this is extremely basic. I'm just sorta thinking out loud here with some initial thoughts. For some reason this seems to peak my interest even though I know I should be leaving it alone.. lol

I guess the above being as simple as it is, in a more complex environment with algos using less consistent patterns we would need to store all bid ask data coming in and then run some sort of pattern routines on the information to perhaps show up potential non-human patterns that work with large quantity. Once having filtered certain patterns we would configure our algo to scan live bid/asks for these similar patterns which we have a record of.

One challenge I see though is that as the exchange doesn't time stamp bid offers, we would be left to our own devices in terms of trying to calculate the time stamp and the issue of network latency seems to introduce an element of randomness that may be very difficult to filter out. I'm not an expert in this so wouldn't know how to approach it.

There is a chap who's thread I have followed for a while called @artemiso , I suspect this topic may arouse his interest and would love to hear if he has anything to say on it.

@artemiso if you see this we are basically just throwing around some ideas about Icebergs in the order book and detection mechanisms or approaches to narrow it down, track other players. Would be interested to hear your thoughts if you have some time?

Now that I laid that all out I can't remember what the other issue was that I thought of 1. was network latency for recording accurate timing. 2. has gone down a black hole. When I think of it again will add it.

1Lot

Follow me on Twitter Started this thread Reply With Quote
  #314 (permalink)
 futuretrader 
Como Italy
 
Experience: Intermediate
Platform: Ninjatrader, customized
Trading: ES
Posts: 525 since Feb 2010
Thanks Given: 471
Thanks Received: 643

Thanks for the thoughtful responses.

I don't think there's any way you can reconstruct an 'iceberg' that is created by the institutional bot - it can be randomized over a price range, a time frame, and sizes.

Orders placed as Icebergs at the CME, however, seem more detectable :

Hidden Quantity
A Hidden Quantity order—also called
MaxShow or Iceberg—displays only a
portion of the order to the marketplace.
When the displayed quantity has been
filled, another portion equal to the
displaced quantity is then displayed as a
new order at the bottom of the book.

I'm not sure what they mean by 'displaced quantity', and if I pursue it I think I'd contact CME for more detail and clarification. But I'm also not sure if it's worth pursuing this sort of extra precision, rather than just looking at the overall additions.

In general, my trading tends to improve in inverse proportion to the time I spend programming and tinkering.

Reply With Quote
Thanked by:
  #315 (permalink)
 
ratfink's Avatar
 ratfink 
Birmingham UK
Market Wizard
 
Experience: Intermediate
Platform: NinjaTrader
Broker: TST/Rithmic
Trading: YM/Gold
Posts: 3,633 since Dec 2012
Thanks Given: 17,423
Thanks Received: 8,425


futuretrader View Post
In general, my trading tends to improve in inverse proportion to the time I spend programming and tinkering.

Agree. Only Mondays and Fridays are now programming/research/also half-size trading days. Tuesdays, Wednesdays and Thursdays I really do try to earn my keep, with only left-field ideas onto scribble pad or hot bug-fixes in C# allowed.

Travel Well
Visit my NexusFi Trade Journal Reply With Quote
  #316 (permalink)
 artemiso 
New York, NY
 
Experience: Beginner
Platform: Vanguard 401k
Broker: Yahoo Finance
Trading: Mutual funds
Posts: 1,152 since Jul 2012
Thanks Given: 784
Thanks Received: 2,685

I'll try not to go on record for saying something that I'm not an expert on (CME). On Globex, I think it is more difficult to deal with second generation implied quotes. For iceberg orders, you can detect them to about 90+% accuracy and estimate their sizes down to +/-5% in realtime (it may seem strange that it's more difficult to classify trade initiator than predict iceberg size, but there's mathematical intuition for this because the constraints here are well-defined). So detection is not the interesting part - the challenge depends on what you would do even if you can see all hidden orders in the order book.

Reply With Quote
  #317 (permalink)
 
Silvester17's Avatar
 Silvester17 
Columbus, OH
Market Wizard
 
Experience: None
Platform: NT 8, TOS
Trading: ES
Posts: 3,603 since Aug 2009
Thanks Given: 5,139
Thanks Received: 11,527


Big Mike View Post
I will refresh Silvester's memory.

Banned for self promotion, in other words advertising his vendor business on nexusfi.com (formerly BMT).

Everyone that signs up is clearly told:

*** If you are selling anything of any kind (vendor) or are affiliated with a vendor in any way

We have a zero tolerance policy with vendors using posts on our forum to promote their business. So, first you must notify us before making any post so that your account is clearly flagged as a vendor. Further, vendors are not permitted to make any posts in which you promote your business in any way. This means no promotional posts linking to your website, blog, videos, screenshots showing indicators or systems, or any discussing of products, services, testimonials. Doing so will result in you being banned. ***

Some remnants here, but I believe the rest was sent to me via private message leading to his ban:


Mike

@Big Mike,

thanks for the refresh

this is not a critique, and I know it's a fine line. and the most important it's your forum with your rules. I would just like to point out, that everything always depends. which of course is just human nature.

the following post shows a vendor posting a video with his indicators. I don't have a problem with that at all. this vendor, as I believe, is well respected here. but someone else doing the same thing might have ended up in big trouble.




Reply With Quote
  #318 (permalink)
 
Big Mike's Avatar
 Big Mike 
Manta, Ecuador
Site Administrator
Developer
Swing Trader
 
Experience: Advanced
Platform: Custom solution
Broker: IBKR
Trading: Stocks & Futures
Frequency: Every few days
Duration: Weeks
Posts: 50,444 since Jun 2009
Thanks Given: 33,217
Thanks Received: 101,608


Silvester17 View Post
@Big Mike,

thanks for the refresh

this is not a critique, and I know it's a fine line. and the most important it's your forum with your rules. I would just like to point out, that everything always depends. which of course is just human nature.

the following post shows a vendor posting a video with his indicators. I don't have a problem with that at all. this vendor, as I believe, is well respected here. but someone else doing the same thing might have ended up in big trouble.




It comes down to context and intent based on my (and others) point of view. I know your feelings already based on your actions. No need to derail this thread further.

Mike

We're here to help: just ask the community or contact our Help Desk

Quick Links: Change your Username or Register as a Vendor
Searching for trading reviews? Review this list
Lifetime Elite Membership: Sign-up for only $149 USD
Exclusive money saving offers from our Site Sponsors: Browse Offers
Report problems with the site: Using the NexusFi changelog thread
Follow me on Twitter Visit my NexusFi Trade Journal Reply With Quote
  #319 (permalink)
 
1LotTrader's Avatar
 1LotTrader 
Douglas, United Kingdom
 
Experience: Advanced
Platform: Custom
Trading: Bund
Posts: 181 since Jun 2009
Thanks Given: 206
Thanks Received: 445


artemiso View Post
I'll try not to go on record for saying something that I'm not an expert on (CME). On Globex, I think it is more difficult to deal with second generation implied quotes. For iceberg orders, you can detect them to about 90+% accuracy and estimate their sizes down to +/-5% in realtime (it may seem strange that it's more difficult to classify trade initiator than predict iceberg size, but there's mathematical intuition for this because the constraints here are well-defined). So detection is not the interesting part - the challenge depends on what you would do even if you can see all hidden orders in the order book.

I need to do some reading up on "second generation implied quotes", no idea what that is.

I agree that having deciphered where various Icebergs are in the book and potential size is not necessarily particularly helpful since who is to say what is the predictive capacity.

The reason it piqued my interest was the idea of potentially being able to identify a subsection of players in the book by identifying what could potentially be signatures or identifiable patterns that there algo's use to refresh there orders. Not to say this would in anyway be possible but understanding the mechanisms involved, the approach and the challenges one would face in trying to accomplish such a task I think would be a general improvement of ones own knowledge on the subject, or at least mine anyway.

I need to go do a bit more Iceberg research myself to understand exactly how those orders are working. I've seen Iceberg options on my CQG platform. I've always assumed that it's an order type that like Ninja's local orders does not sit on the exchange itself but CQG basically holds the info and then fires them in with an algo. I also thought that other firms would do similar and big players would all have there own algos for dropping orders. So potentially there is few different types of algo's for Icebergs but again I am just thinking out aloud. I need to go and do some reading really.

Appreciate you coming to share your thoughts here @artemiso.

1Lot

Follow me on Twitter Started this thread Reply With Quote
Thanked by:
  #320 (permalink)
Adiratus
Bratislava
 
Posts: 12 since Jan 2013
Thanks Given: 16
Thanks Received: 7


Hello guys, here is the newest presentation from Pete.

Recording Information

The begining is vague, later it is more direct to the point.

Reply With Quote




Last Updated on February 19, 2014


© 2024 NexusFi™, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
All information is for educational use only and is not investment advice. There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Privacy Policy - Downloads - Top
no new posts