I cant show you what it looks like - because it has no presentation element - it merely subscribes to rate updates, opens a network socket and transmits the tick updates. Its part of a Tick Capture mechanism.
A separate process should accept socket updates and, if it chooses, capture tick updates for analysis or external backtesting, or act as a feed for alternate trading capabilities. You deploy 1 indicator per chart you wish to capture. I will be producing a robot version if it offers any advantages over the indicator - once i know the differences :!: for this usage
I have chosen to post to a network socket rather than log to a file to add flexibility -
- it is possible to log to a common capture file using a single capture process, which means you can have a capture file that maintains fairly strict temporal ordering - important if you are looking closely at cross pair temporal ordering of updates
- alternate trading mechanism (trading algo containers, gui trading mechanism) receive the update with very little additional latency (<1ms for a local network call) compared with scanning the tail of a feed file
It is capable of emitting changes to top of book only, or to the whole cTrader aggregated price book. So far, the tick rate of the top of book updates have matched (within 10%) the equivalent Empty4 platform for the broker (IC Markets) but i do receive many more event updates for the book as a whole, which can act to CONFIRM the top of book is still current
I am running against IC Markets and plan to test against Pepper cTrader live when it is available
Here is an example of the messages sent to the network socket:
Code: Select all
2013.06.13 09:26:39.529,cicm,EURUSD,1.33454,1.33456
2013.06.13 09:26:39.545,cicm,AUDUSD,0.94852,0.94856
2013.06.13 09:26:39.688,cicm,USDCHF,0.91860,0.91870
2013.06.13 09:26:39.687,cicm,AUDUSD,0.94852,0.94852
2013.06.13 09:26:39.801,cicm,USDCHF,0.91861,0.91870
2013.06.13 09:26:39.796,cicm,AUDUSD,0.94847,0.94847
TickCaptureIndicator.cs - one pair per chart - deploy indicator on any timeframe but only once per pair - i have 30+ charts, 30+ indicators - It opens a network connection to "Host", "Port" and starts streaming "BookLevels" to that stream - each entry as above where Is defaults to "icmc". If BookLevels=1 then it will only emit the price when the top of book changes, all BookLevels>1 emit the whole book on every tick, whether it changes or not (about 2-300% more ticks than top of book changes)
TickCaptureIndicatorX.cs - in progress - deploy on one chart only - will capture all pairs specified and emit on a single stream