API Support Forum
OEC API > API Support > Reliability of BID & ASK data and events priority
Author Topic: Reliability of BID & ASK data and events priority
(3 messages, Page 1 of 1)
Moderators: VPfau
CChen15
Posts: 121
Joined: Jul 23, 2009


Posted: Oct 13, 2011 @ 10:02 AM             Msg. 1 of 3
Hello.

We have four real time events in OECAPI COM that gives us nine possible sources
of BID & ASK data. They are:

1. OnDOMChanged
(1) Contract.DOM.BidLevels.Item(0) & .BidSizes.Item(0)
(2) Contract.Price.BidPrice & .BidVol

2. OnTicksReceived
(3) Ticks.BidPriceList.Item(0)
(4) Subscription.Contract.DOM.BidLevels.Item(0) & .BidSizes.Item(0)
(5) Subscription.Contract.Price.BidPrice & .BidVol

3. OnPriceTick
(6) Contract.DOM.BidLevels.Item(0) & .BidSizes.Item(0)
(7) Price.BidPrice & .BidVol

4. OnPriceChanged
(8) Contract.DOM.BidLevels.Item(0) & .BidSizes.Item(0)
(9) Price.BidPrice & .BidVol


All of them can give us BID & ASK price levels and their sizes (exept Ticks
object, that gives no sizes) on the first (zero, in API notation) DOM level.

Which of them are most reliable for fresh BID & ASK data recieving? "Reliable"
means here that we can do at least one trade on levels indicated by this
event (method).

Which method is "leading" and gives us fresh changed BID & ASK data first of all and
which is delayed, comparing to others? In other words - what is the priority of
mentioned methods in which data are coming?

Because the 4-th 'OnPriceChanged' "...could skip some price updates, if they
come too often" lets not talk about it if I'm right in this assumption of
course.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Chen Hua, Russia
VictorV
Posts: 746
Joined: May 08, 2007


Posted: Oct 13, 2011 @ 10:06 AM             Msg. 2 of 3
Because DOM, quotes and ticks are coming from one data source, but via parallel ways, it is impossible to say with 100% accuracy that the latest DOM is more fresh than the latest quote or ticks. The level of accuracy is around 250 msec.

But user can make decision what event to use on the base of throttling scheme:

1. OnTicksReceived are coming without any throttling.
2. OnDomChanged and OnPriceTick are coming with equal server-side throttling. But DOM updates can be throttled more intensively on vendor/exchange level due higher required bandwidth.
3. OnPriceChanged includes OnPriceTick throttling plus client-side one that depends how fast client application handles OnPriceChanged events. Client application can setup minimum delay between OnPriceTick and OnPriceChanged event via OECClient.EventBatchInterval property.

Victor Vins
Lead Software Developer
CChen15
Posts: 121
Joined: Jul 23, 2009


Posted: Oct 13, 2011 @ 10:17 AM             Msg. 3 of 3
VictorV, thank you for prompt and useful explanation.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Chen Hua, Russia