Keyboard Shortcuts
ctrl + shift + ? :
Show all keyboard shortcuts
ctrl + g :
Navigate to a group
ctrl + shift + f :
Find
ctrl + / :
Quick actions
esc to dismiss
Likes
- Twsapi
- Messages
Search
Re: Flex Queries: Order Reference always empty
I agree, this could easily be in the top 5 features on my wishlist, even though with the daily report mail-ins it would merely offer convenience rather than a full blown upgrade. I would even settle for just keeping my api order numbers because with proper math one could chop a few bits to store custom flags and small numbers. Unfortunately it doesn't look possible either. §é§ä, 11 §Þ§Ñ§â. 2021 §Ô., 2:17 corneliu maftuleac <corneliu.maftuleac@...>: This is why orderRef (or a similar customer-supplied field) should be int64 instead of string, then no issues with storage. |
Re: Flex Queries: Order Reference always empty
True but OrderRef reset is an exception I wouldn't blame them for. Didn't test its limits but obviously clients can stuff A LOT of data into this field at zero cost to them so I imagine it could easily get out of hand for IB if they kept all of it on their servers forever.
|
Re: Flex Queries: Order Reference always empty
Since you are throwing situations there is another to add: Or that there is a business advantage for them to reset; Like playing the spreads or market at times they see fit by taking the opportunity away from others by resets. Technical difficulties alone don't make sense. On Wed, Mar 10, 2021, 4:52 PM Nick <news1000@...> wrote:
|
Re: Flex Queries: Order Reference always empty
Nick
¿ªÔÆÌåÓýIB is all-in with daily resets. I don't know if they painted
themselves into a corner long ago and would essentially have to
start over, or if there is some kind of regulatory or legal
explanation. It doesn't seem like technology itself requires a
broker to go offline every day. On 3/10/2021 4:37 PM, corneliu
maftuleac wrote:
Thanks for the reply. |
Re: Flex Queries: Order Reference always empty
corneliu maftuleac
Thanks for the reply.
Already doing this, however reports are supposed to be self-sufficient.? External tools may fail, mails may get lost, etc. It is very unfortunate that IB does not keep that info, I wonder what technical complexity is keeping them from storing this field in the DB. |
Re: Paper Trading with MKT orders
I would strongly recommend that you record the pricing that IB believes is available at the time, it will tell you whether it is a data issue or a simulated trade issue. At least if the data lines up you know where to focus, if it does not, well, you have your answer? Best wishes, M On Wed, 10 Mar 2021, 20:59 kris k, <kaykay.krish8@...> wrote:
|
Re: Paper Trading with MKT orders
Thanks Mark. I do account for timing differences in my backtest (i.e I assume there is a time delta between when my model signal is generated and when the orders are actually placed. So in backtest, I look for the price traded at that specific time and evaluate model performance). I even assume worst?of bid/ask at that time.? But IB paper trading ends up far worse On Wed, Mar 10, 2021 at 12:42 PM mark collins <mark.collins@...> wrote:
|
Flex Queries: Order Reference always empty
corneliu maftuleac
I am using orderRef field of an order to mark an order as it belongs to a specific strategy.
However when using flex queries to retrieve the list of orders the OrderReference field is always empty. As specified on the docs: The order reference number as defined by the user on the order ticket.? Any ideas how to retrieve order reference? |
Re: Paper Trading with MKT orders
To really understand this you'll need to account for possible differences in the exchanges, as well as the timing differences. Lastly you need to know that paper trades in the IB system are approximated, you may find real money trades differently. As a start I would want to validate that the prices reported are possibly tradable at the times reported in both places. Best wishes, M On Wed, 10 Mar 2021, 20:10 , <kaykay.krish8@...> wrote: Hello |
Paper Trading with MKT orders
Hello
Can anyone tell me how the IBKR paper trading via APIs is simulated ? This is how I am testing my system. I have a 3rd party tick data that I consume and build my predictions real-time (so I am not using any of the data feed from IBKR). When I place MKT order, is IB paper trading going to assume top of the bid/ask or is this last trade price or something else. I am not able to find any details on this. I would be grateful if anyone provide pointers.? When I compare my model performance after end of day using 3rd party tick data, I find the paper trading account and my own backtest significantly differs (I do account for slippage in time for my model computation and when the trade actually get placed) Thanks kris |
Multiple connections and multiple accounts
I have a few accounts under a Friends? and Family umbrella account which
I trade using multiple python based models.?? I had been successfully trading two models against one of the accounts, but when I added another model trading against a second account I ran into a problem with account? and position updates.? I should point out that each model is independent, requesting it's own data subscriptions and placing it's own trades. I had been using reqAccountUpdates() to automatically update account values and portfolio stats.? That failed when I added the second account because reqAccountUpdates can only be subscribed to a single account at a time even across multiple connections.? I shifted to using reqAccountUpdatesMulti() combined with reqPositionsMulti() in all models and this seems to work.? The potential weakness is that one looses the AccountReady flag with this option. I'm wondering if I am missing something that is obvious to the veterans on the list.? Or, a better question might be, what are others doing in this regard?? Are you tracking account balances and position sizes within your code rather than using api requests?? I do that in some cases for position size but typically like to access cash balances from the api. While I'm asking questions let me ask one about data subscription lines.? If hypothetically each of my three models is subscribing to the same 10 symbols is that 10 data lines or 30? Thanks for your thoughts, Hugh |
Re: tickeByTickData or Depth Level 2 does not work when using ISIN instead of conID or symbol
Thanks for checking this. Your example works for contract details but have you seen this working for market depth level 2 or level 1 as well which is the case I am asking about? Side note: Will download this tool. Are there other tools like this as well that you know of? Thanks, On Tue, Mar 9, 2021, 5:17 PM JR <TwsApiOnGroupsIo@...> wrote: Maybe you want to check your setup, Bruce. The ISIN example contract lookup example works just fine in Richards amazing Contract Inspector. |
automated RTD download completion detection
Does anyone know how to make a routine that determines when all the RTD cells have been updated?.? That way the next procedure can detect it and run based on the data.? I currently have to wait and manually look to see when I think the cells have been updated but it seems like there should be some automated way of doing it.? The problem I have with automating it is that RTD won't update while I'm running the routine to download and check it.? Also, if I tell the system to wait, RTDs doesn't update during the wait or even if I put in a DoEvents command.
|
Re: tickeByTickData or Depth Level 2 does not work when using ISIN instead of conID or symbol
Maybe you want to check your setup, Bruce. The ISIN example contract lookup example works just fine in Richards amazing Contract Inspector.
toggle quoted message
Show quoted text
On Tue, Mar 9, 2021 at 03:53 PM, Bruce B wrote:
|
Re: tickeByTickData or Depth Level 2 does not work when using ISIN instead of conID or symbol
Thanks Stew. Noted your tip about why conID might give faster response. The error I get you think is because I didn't input contract ID or symbol like it says? If so then: A) Why does the sample file not include it? B) What is the point of adding ISIN if it still need conID or symbol like the error says? Code: 321, Msg: Error validating request.-'b0' : cause - The symbol or the local-symbol or the security id must be entered ? This is from Contract samples.java which exists in cpp++ samples too: public static Contract ByISIN() { Contract contract = new Contract(); contract.secIdType("ISIN"); contract.secId("US45841N1072"); contract.secType("STK"); contract.currency("USD"); contract.exchange("SMART"); return contract; } Anyone else knows why I get the error? Maybe ISIN use is limited to orders only and can't be used with market data subscriptions? Thanks, On Fri, Mar 5, 2021, 2:32 PM Stewie D <sdouglas@...> wrote:
|
Is it possible to get Book Depth Level 2 from historical data?
Hi,
Is it possible to get "Book Depth Level 2" detail levels from Historical Data requests? In streaming data this comes from these requests: I am wondering what the equivalent is in Historical Data. If this is not available, what is the highest detail possible to get from Historical Data and which function provides this? Thanks, |
reqHeadTimeStamp Duplicate Query Error
My script requests the head timestamp of 200 contracts to query data.? I have been having a few issues:
self.cancelHeadTimeStamp(reqid)Is there any clarity into what these errors exactly mean?? Am I being throttled?? Sometimes the script works perfectly, and other times it gets held up. Mike |
to navigate to use esc to dismiss