API Support Forum
User Profile

Viewing User Profile for: npn


About

Apr 14, 2008 09:30 PM

May 29, 2008 02:15 PM

May 29, 2008 08:13 PM



Post Statistics
npn has contributed to 19 posts out of 5593 total posts (0.34%) in 5862 days (0.00 posts per day).

20 most recent posts:

API Support » Slippage May 29, 2008 @ 02:15 PM (Total replies: 26)

I observe the same issue today.

I strongly believe the problem is with your data. The more subscriptions I make the more often the slippage is. Another reasons for that I believe is the auto-subscription (in my case the Pit contracts). I'd subscribe for 3 quotes and in reality I get 6. That would delay the processing on your side, wouldn't it?

Any progress on your research? Can you provide a log with the quotes/trades around the time of my trades?

Sorry, but unless we resolve this we have no choice but to suspend live trading.

API Support » Slippage May 28, 2008 @ 03:37 PM (Total replies: 26)

Thanks for your fast reply as usual.

I understand the issue with the throttled data and I measure the slippage in a different way than originally. Here’s a possible scenario:

1. OnPriceChanged event rises, with OEC.API.Price of Bid/Ask: 197.78/197.79 on 20080528-18:29:49.582
2. Strategy triggers and sends orders within 10 microseconds
3. ~50ms later at 20080528-18:29:49.629 I receive a Fill for my Buy order at 197.81 (2 ticks higher)

I understand that slippage is part of the business, but about 90% of the time is just NOT NORMAL. I don’t know if the 54ms response is the issue, I believe it could be since, again, our server is only 1ms away from yours, also I understand that your server is less that 1ms away from the CME’s.

API Support » Slippage May 28, 2008 @ 02:40 PM (Total replies: 26)

I guess our problems continue. I assume that the multiple contract subscription slows down your system, as that’s the only thing that has changed on our side. With one contract price subscription we get about 40% slippage, which is still very high, but with 3 contracts, the data below shows that we get price decline of 1-2 ticks about 90%.

I’ve also logged the order-fill times which average to about 54ms. Note, our server is in a close proximity of yours, and pinging it comes back with 1ms average.

These are LIVE orders from today, in 5 out 6 there was a price slippage, of total 7 ticks:

LimitSell Order sent: Sell 1 6EM8 MKT Bid/Ask: 156.09/156.10 :20080528-12:40:06.582
OnOrderConfirmed OrderID: 8616278
5/28/2008 12:40:06 PM Sell 1 6EM8 MKT Sent
5/28/2008 12:40:06 PM Sell 1 6EM8 MKT Working
5/28/2008 12:40:06 PM Sell 1 6EM8 MKT Completed
5/28/2008 12:40:06 PM/20080528-12:40:06.629 Sell 1 6EM8 MKT Completed Fill:1@156.08
Slippage: 1 Tick


LimitSell Order sent: Sell 2 6BM8 MKT Bid/Ask: 197.75/197.76 :20080528-14:28:25.144
OnOrderConfirmed OrderID: 8622565
5/28/2008 2:28:24 PM Sell 2 6BM8 MKT Sent
5/28/2008 2:28:24 PM Sell 2 6BM8 MKT Working
5/28/2008 2:28:24 PM Sell 2 6BM8 MKT Completed
5/28/2008 2:28:24 PM/20080528-14:28:25.223 Sell 2 6BM8 MKT Completed Fill:1@197.75
5/28/2008 2:28:24 PM/20080528-14:28:25.223 Sell 2 6BM8 MKT Completed Fill:1@197.74
Slippage: 1 Tick


LimitBuy Order sent: Buy 2 6BM8 MKT Bid/Ask: 197.75/197.76 :20080528-15:00:25.879
OnOrderConfirmed OrderID: 8624777
5/28/2008 3:00:25 PM Buy 2 6BM8 MKT Sent
5/28/2008 3:00:25 PM Buy 2 6BM8 MKT Working
5/28/2008 3:00:25 PM Buy 2 6BM8 MKT Completed
5/28/2008 3:00:25 PM/20080528-15:00:25.910 Buy 2 6BM8 MKT Completed Fill:1@197.76
5/28/2008 3:00:25 PM/20080528-15:00:25.910 Buy 2 6BM8 MKT Completed Fill:1@197.77
Slippage: 1 Tick


LimitSell Order sent: Sell 2 6BM8 MKT Bid/Ask: 197.81/197.82 :20080528-16:36:02.269
OnOrderConfirmed OrderID: 8629462
5/28/2008 4:36:02 PM Sell 2 6BM8 MKT Sent
5/28/2008 4:36:02 PM Sell 2 6BM8 MKT Working
5/28/2008 4:36:02 PM Sell 2 6BM8 MKT Completed
5/28/2008 4:36:02 PM/20080528-16:36:02.301 Sell 2 6BM8 MKT Completed Fill:2@197.79
Slippage: 2 Ticks

LimitBuy Order sent: Buy 2 6BM8 MKT Bid/Ask: 197.78/197.79 :20080528-18:29:49.582
OnOrderConfirmed OrderID: 8634659
5/28/2008 6:29:49 PM Buy 2 6BM8 MKT Sent
5/28/2008 6:29:49 PM Buy 2 6BM8 MKT Working
5/28/2008 6:29:49 PM Buy 2 6BM8 MKT Completed
5/28/2008 6:29:49 PM/20080528-18:29:49.629 Buy 2 6BM8 MKT Completed Fill:2@197.81
Slippage: 2 Ticks


I look forward to your comments.

API Support » Login May 21, 2008 @ 09:13 AM (Total replies: 2)

Is the api server down?

API Support » Login May 21, 2008 @ 07:45 AM (Total replies: 2)

I get an error trying to log in to the demo (api) environment: "Connect to OEC Server failed. Please, check your internet connection. Tyepid 296 is not registered".

Please advice.

API Support » Auto Subscribe May 14, 2008 @ 12:16 PM (Total replies: 5)

SergeK,

Reading your post #2 above, for currency contracts, would it mean that if my position was for 6EM8, there would be an automatic subscription for ECM8?

API Support » Slippage May 08, 2008 @ 09:13 AM (Total replies: 26)

Is there a further development on this matter?

I have continued to log orders, price and slippage, which support the cases where the current price before sending the order, and after is the same, however the order fills at different.

API Support » Slippage May 07, 2008 @ 09:41 AM (Total replies: 26)

As my results showed, not much cases of slippage in the api env. compared to prod, so I don’t know how many I would get. Here are 2, and I’ll provide more as soon as I get more:

5/7/2008 1:32:06 PM Buy 1 6EM8 MKT Sent
>>>LimitBuy Order sent: Buy 1 6EM8 MKT Bid/Ask: 153.71/153.72
OnOrderConfirmed OrderID: 200008315
5/7/2008 1:32:06 PM Buy 1 6EM8 MKT Sent
5/7/2008 1:32:06 PM Buy 1 6EM8 MKT Working
5/7/2008 1:32:06 PM Buy 1 6EM8 MKT Completed
5/7/2008 1:32:06 PM Buy 1 6EM8 MKT Completed Fill:1@153.73

5/7/2008 1:39:35 PM Buy 1 6EM8 MKT Sent
>>>LimitBuy Order sent: Buy 1 6EM8 MKT Bid/Ask: 153.61/153.62
OnOrderConfirmed OrderID: 200008327
5/7/2008 1:39:35 PM Buy 1 6EM8 MKT Sent
5/7/2008 1:39:35 PM Buy 1 6EM8 MKT Working
5/7/2008 1:39:35 PM Buy 1 6EM8 MKT Completed
5/7/2008 1:39:35 PM Buy 1 6EM8 MKT Completed Fill:1@153.63

API Support » Slippage May 07, 2008 @ 08:55 AM (Total replies: 26)

This almost looks like re-quotes where the slippage is always against us. If there was a delay in your data feed for some reason, slippage could be in our favor too.

My app ran on your demo environment all night, and there was slippage there too, for about 7 orders out of 34, no larger than 2 pips.

Let me know if we can organize some collaborative test where we can verify and address the problem. We’re looking forward to your findings.

API Support » Slippage May 06, 2008 @ 05:06 PM (Total replies: 26)

I have no Windows components that are update by any of the OEC API events; I had that concern too. The creation of an order itself could “pause” the quote updates, and/or the incoming quotes can prevent the order from being sent immediately.

Is there a way to take the Quotes events e.g. OnPriceChanged to another thread?
I don’t see this particularly helping, but worth a try.

Is there anything else you can suggests or check? Do you expect that using the DOM class would enhance performance (there’s a bit more processing there)?

API Support » Slippage May 06, 2008 @ 03:59 PM (Total replies: 26)

Our application runs on a dedicated server so I don’t much expect problems there.

I’ve used the basics from the Advanced API example, but stripped the majority of the code. No graphics, no intense calculations. Very simple application for 100% automated trading. I watch the executions with a read-only user from another machine.

My results in your api (demo) environment were slightly better with Market Orders, and much better with Limit Orders.

Can you recommend a code sample that I can take a look at? What about the DOM?

API Support » Slippage May 06, 2008 @ 03:48 PM (Total replies: 26)

No, I haven't used Trader DOM. My code is based on your Advanced API Example.

My only conclusion is that your data is delayed - could be because of your throttling.

Is there a phone number I can reach you at? It would be easier to address a few questions.

API Support » Slippage May 06, 2008 @ 02:58 PM (Total replies: 26)

Another one just now (in a very slow market):

5/6/2008 6:40:42 PM Buy 1 6EM8 MKT Sent
>>>LimitBuy Order sent: Buy 1 6EM8 MKT Bid/Ask: 155.09/155.10
OnOrderConfirmed OrderID: 8199847
5/6/2008 6:40:42 PM Buy 1 6EM8 MKT Sent
5/6/2008 6:40:42 PM Buy 1 6EM8 MKT Working
5/6/2008 6:40:42 PM Buy 1 6EM8 MKT Completed
5/6/2008 6:40:42 PM Buy 1 6EM8 MKT Completed Fill:1@155.13

Fill @ 155.13 and the Ask was 155.10. Slippage: 3

API Support » Slippage May 06, 2008 @ 02:43 PM (Total replies: 26)

My system logs the price as contract.CurrentPrice.BidPrice/contract.CurrentPrice.BidAsk right after the “oecClient.SendOrder” command.

For example:

5/6/2008 3:24:21 PM Buy 1 6EM8 MKT Sent
>>>LimitBuy Order sent: Buy 1 6EM8 MKT Bid/Ask: 155.29/155.30
OnOrderConfirmed OrderID: 8188939
5/6/2008 3:24:21 PM Buy 1 6EM8 MKT Sent
5/6/2008 3:24:21 PM Buy 1 6EM8 MKT Working
5/6/2008 3:24:21 PM Buy 1 6EM8 MKT Completed
5/6/2008 3:24:21 PM Buy 1 6EM8 MKT Completed Fill:1@155.32

Fill @ 155.32 and the Ask was 155.30. Slippage: 2

More:

5/6/2008 5:41:12 PM Sell 1 6EM8 MKT
>>>LimitSell Order sent: Sell 1 6EM8 MKT Bid/Ask: 155.10/155.11
OnOrderConfirmed OrderID: 8196822
5/6/2008 5:41:12 PM Sell 1 6EM8 MKT Sent
5/6/2008 5:41:12 PM Sell 1 6EM8 MKT Working
5/6/2008 5:41:12 PM Sell 1 6EM8 MKT Completed
5/6/2008 5:41:12 PM Sell 1 6EM8 MKT Completed Fill:1@155.08

Fill @ 155.08 and the Bid was 155.10. Slippage: 2

5/6/2008 6:19:01 PM Buy 1 6EM8 MKT Sent
>>>LimitBuy Order sent: Buy 1 6EM8 MKT Bid/Ask: 154.94/154.95
OnOrderConfirmed OrderID: 8199030
5/6/2008 6:19:01 PM Buy 1 6EM8 MKT Sent
5/6/2008 6:19:01 PM Buy 1 6EM8 MKT Working
5/6/2008 6:19:01 PM Buy 1 6EM8 MKT Completed
5/6/2008 6:19:01 PM Buy 1 6EM8 MKT Completed Fill:1@154.95

Fill @ 154.95 and the Ask was 154.95. Slippage: 0

API Support » Slippage May 06, 2008 @ 02:10 PM (Total replies: 26)

These are all live orders.

The order you referring to had a slippage of 2 pips. Also the one before that with ID 1799559.

If there’s nothing wrong with the orders, how come there’s a slippage on almost all of them? These 2 are fresh example of 2 consecutive orders with a slippage of 2 pips each.

Regarding Limit Orders with Market Price, I believe I had specified the price as you suggested with the opposing side price. For example current price is 154.55/56, I’d send a buy limit order with price of 154.56. Is this what you meant?

I understand the concept and I’ve seen slippage, but this is almost 100% of the time.

API Support » Slippage May 06, 2008 @ 01:13 PM (Total replies: 26)

Hi,

I've sent 20 live orders through the API for the last couple of days, and I've gotten some unusual slippage. The average slippage is about 2 ticks, but I've had a few cases with 3 and 4 ticks. I’ve logged extensively the activity and my results show that from the time I’ve received your quote to the time the order is out, it takes about 10 microseconds. The actual fills occur in about 50 milliseconds.

I’ve also sent 3 Limit Orders at market price, and none executed.

To me, it’s obvious that by the time my orders are processed, the price have moved. The only way to explain this is that your API quotes are stale, as again, the turnaround time on my side is extremely low.

Please advise!

API Support » Trade Log Apr 16, 2008 @ 02:43 PM (Total replies: 6)

Is the log generation removed from the release version for performance reasons?

I think the log is a good idea even with the production version. For one I don't have to build my own log.

API Support » Trade Log Apr 16, 2008 @ 10:27 AM (Total replies: 6)

There's a log file generated by the application residing by default in the directory where the exe file is ran from.

Is there a way to specify a directory for that log file?

API Support » Duplicate Order Number Apr 14, 2008 @ 09:37 PM (Total replies: 1)

I got orders rejected with a "Duplicate external order number" comment.

I don't understand why I get this message as nowhere in the code I supply an external order number. My orders generation code is a copy of the basic API example.

Any ideas why I get this message?

Thanks.