{"id":248,"date":"2014-01-18T20:23:07","date_gmt":"2014-01-18T20:23:07","guid":{"rendered":"http:\/\/www.stirfutures.co.uk\/?p=248"},"modified":"2018-11-16T21:14:31","modified_gmt":"2018-11-16T21:14:31","slug":"liffes-stir-matching-algorithm","status":"publish","type":"post","link":"https:\/\/www.stirfutures.co.uk\/?p=248","title":{"rendered":"LIFFE&#8217;s STIR matching algorithm"},"content":{"rendered":"<p>Matching algorithms are the mathematical equations within the computer code of the Exchange matching engine, known as CONNECT on LIFFE.\u00a0 These algorithms allocate incoming market orders amongst the resting order depth using a methodology somewhere between a pure pro rata and pure time priority, also known as first in-first out (FIFO).<\/p>\n<p>LIFFE operates two matching algorithms for its STIR futures: one for Euribor and the other for Short Sterling and Euroswiss. They combine both pro-rata and time priority but the Short Sterling \/Swiss version has a higher bias towards time priority.<\/p>\n<p>Both algorithms have the same mathematical structure. The current algorithm for the Euribor is:<\/p>\n<p><a href=\"http:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/a.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-313\" src=\"http:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/a.png\" alt=\"a\" width=\"680\" height=\"448\" srcset=\"https:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/a.png 680w, https:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/a-300x197.png 300w\" sizes=\"auto, (max-width: 680px) 100vw, 680px\" \/><\/a><\/p>\n<p>The current algorithm for Short Sterling and Euroswiss is similar but to a higher order*.<\/p>\n<p><a href=\"http:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/Capture.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-315\" src=\"http:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/Capture.png\" alt=\"Capture\" width=\"385\" height=\"137\" srcset=\"https:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/Capture.png 385w, https:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/Capture-300x106.png 300w\" sizes=\"auto, (max-width: 385px) 100vw, 385px\" \/><\/a><\/p>\n<p>*The Time Exponent employed within the Gradual Time Based Pro Rata (GTBPR) matching algorithm will change from 4 to 2 effective on Monday 3 December 2018<\/p>\n<p>An easy way to consider these algorithms is as if the order is set to 1 (i.e. there are no powers). In this case, any incoming order of reasonable size is split amongst resting orders in an equal percentage weighting.<\/p>\n<h2>Example<\/h2>\n<p>The table shows an incoming order of 200 lots into a market with a resting order depth of 2405 lots made up of 10 individual orders of different size and ranked by time priority. \u00a0\u00a0It could be considered as a market order to sell 200 lots at best when the market is 99.00 bid for 2405 lots. The 2405 lots on the bid are made up of 10 separate orders all bidding the same price but entered at different times. The order with the oldest timestamp will be T1 and the newest T10.<\/p>\n<p><a href=\"http:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/algo1.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-339\" src=\"http:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/algo1.jpg\" alt=\"algo1\" width=\"319\" height=\"336\" srcset=\"https:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/algo1.jpg 319w, https:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/algo1-284x300.jpg 284w\" sizes=\"auto, (max-width: 319px) 100vw, 319px\" \/><\/a><\/p>\n<p>It can be seen that all orders (T1 through to T10) get 8% of their resting order size. In absolute terms, the larger the bid, the more futures would have been bought. \u00a0It might be noted that only 194 futures were transacted and so the algorithm would then make another pass to allocate the remaining 6.<\/p>\n<p>This is an example of pure pro rata and would advantage those <i>over quoting<\/i> by flashing large orders into the market depth momentarily before the order hits the market and would provide no advantage to consistent resting liquidity providers. \u00a0To circumvent this, the actual algorithms operate to a power; two in the case of Euribor and four in the case of Short Sterling and Euroswiss.<\/p>\n<p>The same order and market depth then experiences a very different allocation. The Euribor algorithm allocates on a broadly linear but decreasing profile (in percentage terms) whereas the Sterling\/Swiss algorithm would allocate a much higher proportion to the first three time priority orders (T1-T3) with sharply decreasing density thereafter for the remainder. In both cases, orders towards the back of the queue get no allocations.<\/p>\n<p><a href=\"http:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/algo2.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-340\" src=\"http:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/algo2.jpg\" alt=\"algo2\" width=\"311\" height=\"304\" srcset=\"https:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/algo2.jpg 311w, https:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/algo2-300x293.jpg 300w\" sizes=\"auto, (max-width: 311px) 100vw, 311px\" \/><\/a><\/p>\n<p>In graphical terms the effect is more observable.<\/p>\n<p><a href=\"http:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/algo3.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-338\" src=\"http:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/algo3.jpg\" alt=\"algo3\" width=\"523\" height=\"291\" srcset=\"https:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/algo3.jpg 523w, https:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/algo3-300x166.jpg 300w\" sizes=\"auto, (max-width: 523px) 100vw, 523px\" \/><\/a><\/p>\n<p>Both algorithms, but particularly the Sterling one, benefit orders with time priority; the idea being to promote and encourage resting liquidity. Traders are encouraged to supply liquidity early into price points.<\/p>\n<p>The spreadsheet containing both algorithms is available to download<a title=\"LIFFE matching algorithm\" href=\"http:\/\/www.stirfutures.co.uk\/wp-content\/uploads\/2014\/02\/LIFFE-STIR-Algorithm1.xlsx\"> here<\/a>. Now you can figure out for yourself why your fills might not be what you hoped for and perhaps find a way to improve your allocations.<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Matching algorithms are the mathematical equations within the computer code of the Exchange matching engine, known as CONNECT on LIFFE.\u00a0 These algorithms allocate incoming market orders amongst the resting order depth using a methodology somewhere between a pure pro rata and pure time priority, also known as first in-first out (FIFO). LIFFE operates two matching [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[40,39,41],"class_list":["post-248","post","type-post","status-publish","format-standard","hentry","category-uncategorized","tag-liffe-matching-algorithm","tag-matching-algorithm","tag-stir-algorithm"],"_links":{"self":[{"href":"https:\/\/www.stirfutures.co.uk\/index.php?rest_route=\/wp\/v2\/posts\/248","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.stirfutures.co.uk\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.stirfutures.co.uk\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.stirfutures.co.uk\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.stirfutures.co.uk\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=248"}],"version-history":[{"count":9,"href":"https:\/\/www.stirfutures.co.uk\/index.php?rest_route=\/wp\/v2\/posts\/248\/revisions"}],"predecessor-version":[{"id":485,"href":"https:\/\/www.stirfutures.co.uk\/index.php?rest_route=\/wp\/v2\/posts\/248\/revisions\/485"}],"wp:attachment":[{"href":"https:\/\/www.stirfutures.co.uk\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=248"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.stirfutures.co.uk\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=248"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.stirfutures.co.uk\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=248"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}