Hi Matthew, I’m experiencing a very strange problem on C2 right now that whenever I try to enter a STC order for YM or EUR the C2 system will force it to be shown as a conditional order and attach it to a BTO order. Because of this problem I cannot enter any independent STC order right now. Could you please take a look at this problem? Thanks.
That is not a bug. It is a requirement of AutoTrading. We will need to automatically assign orphaned STC orders to an opening order. This will allow subscribers and autotraders to stay in sync. It will not affect your system results or performance in any way, as the "parent" of the conditional order will always be already filled.
Yes it is absolutely a problem here, as what I can see right now is that C2 always attach the newly entered STC order to an open BTO order (meaning … that “parent” BTO order has not been executed yet. It’s an open order!)
By the way, is this something new?
It is a function that kicks in when people are autotrading your system. To understand why it’s necessary, consider the following example. You issue 10 separate BTO orders. Half-way through this process, someone joins your system as an autotrader. Now you issue a STC order. From C2’s perspective, it is unsure which subscriber(s) should get that closing order. Does the closing order “apply” to the first position you opened? To the last?
If you think about it, at the end of the day, it makes ZERO mathematical difference. You will eventually close all your positions, for the same aggregate mathematical result. But from the perspective of C2’s autotrading interface to various brokers, we need to know whether subscriber X should close a position now or later.
So, if you issue a closing order when there are multiple pending opening orders, some of which have been traded by an autotrader, and some of which have not, C2 needs to make a decision about which opening trade the closing trade is attached to. Again, ultimately, the math works out the same. But a decision needs to be made, nonetheless. If you don’t like the decision that C2 makes, then you can assign your own parent order to the closing order in question.
Again, this only happens when there is ambiguity and you have issue multiple opening orders, some of which were not traded by one of your autotraders.
Personally I think this automatic assignment thing is better to be done on the subscriber side rather than on the vender side. But I would have no problem to accept it if C2 can implement it the right way. What I can see right now however is that C2 is attaching a new STC order to an open BTO order - which is simply wrong.
I think C2 should manage to attach a STC order to an already-filled BTO order. C2 should never try to attach a STC order to an open BTO order, as it simply doesn’t make sense. And it affact the vender’s normal trading a lot - just like what has happened to my CCF-EMINI system today (that I simply couldn’t find a way to enter a STC order to close my existing positions).
Not sure if the above have explained my points clearly. If not I can use my today’s example to explain it again in more detail.
If you prefer to do it yourself, you can manually attach the closing order (as a conditional) to any still-pending order you want.
I have tried to explain why it is necessary to attach the closing order to a still-pending order. Again, it does not affect your results (mathematically speaking) regardless of which order it is attached to. But if you do not want it assigned automatically, just specify the order you prefer.
Let me describe in detail what’s the problem I was experiencing this morning with EUM8 trading: this morning when EUM8 was at price of around 1.5431 I have 2 EUM8 contracts (long) in CCF-EMINI system. And the pending orders at that time include 3 BTO orders (at 1.5288, 1.5329, and 1.5350) and 2 STC orders (at 1.5459 and 1.5495). At that time I decided to close one of the EUM8 contracts to protect the profit, so I click on the “STC @1.5459” order trying to change it to “STC @1.5430” (which meant to sell it right away as the bid price then was 1.5431). But then I found that C2 has attached this “STC@1.5430” order to the pending order of “BTO@1.5288” as a conditional order. Now do you see what the problem is? It should be obvious … the problem is that I wanted to sell the position right away at that time but C2 simply doesn’t allow me to do it! And I couldn’t find any other way to attach a STC order to an already-filled-BTO-order because in the trading page I can only see pending orders not the orders that have already been filled.
I think I understand what you are saying.
First, some context: The reason for this seemingly “strange” behavior on the part of C2 is that you have been legging in and legging out of positions over the course of 17 or 18 legs. (I.E. Buy 2, Buy 2 Sell 1, Buy 1, Sell 2 … etc.)
When you have a subscriber/AutoTrader “join late” one of these complex multi-legged trades, it’s hard to have C2 figure out which closing trade is meant to correspond to which opening trade. An AutoTrader who “joins late” will only have seen some of the opening legs, not all. Thus, when you issue a closing leg, there is ambiguity about whether that closing limit or stop is meant to apply to the AutoTrader. When there is ambiguity, C2 makes a decision for you.
Usually this works fine and is not a big deal. But in your case, your actual intentions are a bit different. You are issuing a limit order, but you fully intend for that limit to be filled right away (because the price is marketable). But C2 doesn’t check if the order is marketable, and so it queues it up and attached it to an opening order.
There are two ways to handle this from your perspective. First, if it’s driving you nuts, then you can flatten your current trade and open a new trade. Once a new trade is started, the entire issue of a subscriber “joining a trade late” disappears. Since, in reality, your position is only net long 1 or 2 (or so it seems) this might be the most expedient answer. (I wonder if you are hesitant to close trades because you feel it affects your “stats” – if this is the case then I must discourage this mindset. You will be chasing a gain that is chimerical: C2 uses marked-to-market accounting, and thus closed and open positions have the same statistical value. But let’s put this minor issue aside…)
If you do not want to flatten your position, then you’ll need to handle this in a slightly different way. I understand that your intention is to close a portion of your trade right away (you are issuing a limit order, it is true, but you know that the price is “marketable.”) If this is the case, then you’ll need to issue a true market order, not a limit order. If you issue a market order, C2 will process it right away, and will not try to attach it to a pending opening order.
I know that neither of these answers is exactly what you want to hear, but the issue of keeping autotraders in sync with complex multi-legged trades is a complicated one. C2 is asking you to make what I believe are very minor compromises in order to make everything work smoothly for all parties (system vendor and subscriber).
Matthew
Since writing this last post, I added some code to the order entry routines to check if the limit/stop order you submit is marketable, and - if so - to avoid auto-joining it as a conditional to a parent order. This should catch the circumstances outlined above 80% of the time, but in a fast market, it might miss the fact that your order is marketable… in which case, the advice above will apply. Otherwise, everything should be transparent and you probably won’t have to worry about this issue any more.
Matthew, thanks for your explaination and the effort to have even added some code to fix some special cases. But I have to point out that your current implementation way still cannot fix the whole problem. And on this issue I actually have a simple and straight-foreward solution which I believe should be able to easily fix this problem from the root without having to add any patch code. Here is my solution: whenever C2 sees the vender enter a closing order (unconditional order, of course) and feels that it needs to make decision for the vender to assign this closing order to an opening order it should simply look for an already-filled opening order to attach this closing order to. (Note: the key here is that C2 should NEVER try to assign an unconditional closing order entered by vender to a pending opening order because it simply has changed the original intention of the vender’s unconditional closing order and therefore is wrong.)