Home › Forums › Trading System Mentor Course Community › Running Your Trading Business › MOC BatchTrader Testing
- This topic is empty.
-
AuthorPosts
-
August 1, 2016 at 1:16 pm #101486JulianCohenParticipant
I posted initially about this in my journal but as there is now 3 or 4 of us going the MOC route I though it might be helpful to have a thread for the testing of the addition to the API.
As I mentioned in my journal so far it appears to work flawlessly with the US markets, I have tested it on S&P so far only.
ASX it is not working correctly. Initially Levente said it was because I was entering the exchange as SMART and not ASX but today I tested that and still had the same problem. I’ll let you know his response
August 1, 2016 at 9:15 pm #104933Nick RadgeKeymasterLen says his BatchTrader works on a 24hr clock – maybe try the time in that format instead.
What kind of order is it trying to place?
August 2, 2016 at 12:07 am #104949JulianCohenParticipantNick Radge wrote:Len says his BatchTrader works on a 24hr clock – maybe try the time in that format instead.What kind of order is it trying to place?
Yes it works on a 24hr clock so the ASX cutoff time is set to 15:45. It is trying to place a market order as far as I know but I can’t be certain as I have not seen it do so yet.
I could check it on the S&P tonight and see what it does, but I thought I’d bring it up with Levente as a bug and see what happens from there. He hasn’t written back yet
August 2, 2016 at 12:52 am #104934Nick RadgeKeymasterOK. A market order will not activate in the closing auction. A market order requires a trade to trigger the order and there is no trading in the closing auction.
You either use a MKT order at 15:59 or you use a LMT order (with some discount) after 16:00
August 2, 2016 at 1:16 am #104952JulianCohenParticipantNick Radge wrote:OK. A market order will not activate in the closing auction. A market order requires a trade to trigger the order and there is no trading in the closing auction.You either use a MKT order at 15:59 or you use a LMT order (with some discount) after 16:00
OK. I think Levente’s idea was that at a set time, the API issues market orders so the positions are just closed. I wasn’t thinking about the closing auction. At the moment the API is not issuing those market orders so something must be wrong in that process.
August 3, 2016 at 12:33 am #104953JulianCohenParticipantIt turns out that I have an uncanny knack of breaking software by doing things that the designers never considered. The MOC BatchTrader has a section that allows you to set the cut off time for cancelling the remaining orders and then placing market orders to close the positions.
I was placing a space after the comma between the two exchanges and this caused the program to read the exchange as ” ASX” instead of “ASX” and therefore failed. This has now been fixed so that any errant commas will be ignored.
Levente has also added a function to allow an order ID to be placed in the system so when running two instances of Batch Trader you can identify easily trades done on each one.
I’ll test this and let you know.
August 3, 2016 at 2:06 am #104962LeeDanelloParticipantJulian Cohen wrote:It turns out that I have an uncanny knack of breaking software by doing things that the designers never considered. The MOC BatchTrader has a section that allows you to set the cut off time for cancelling the remaining orders and then placing market orders to close the positions.I was placing a space after the comma between the two exchanges and this caused the program to read the exchange as ” ASX” instead of “ASX” and therefore failed. This has now been fixed so that any errant commas will be ignored.
Levente has also added a function to allow an order ID to be placed in the system so when running two instances of Batch Trader you can identify easily trades done on each one.
I’ll test this and let you know.
You’re a good beta tester then. They’re meant to find the holes.
August 3, 2016 at 2:11 am #104965JulianCohenParticipantI did it in my last job. I’m great at breaking software!
August 3, 2016 at 9:04 am #104935AnonymousInactiveI use MOC BatchTrader for US stocks, so far all good. Next step I will need to assess where it is worth buying, I got quoted CHF1500 :huh: I will need to question that and make a decision once the trial is up.
My alternative is to use a second BatchTrader (Nick’s API), to place and manage the trades and then manually cancel and close out trades before the close and if I miss it, close out on the next open, but that may open up margin issues. Yesterday I was full up on my MRV system and the exit on close version :ohmy:August 3, 2016 at 9:28 am #104972TrentRothallParticipantI’d suggest if you decide to buy then run it as designed, if you don’t buy then run a system where you can exit next open so you aren’t held hostage by the system everyday at 3-4!
August 3, 2016 at 10:51 pm #104936JulianCohenParticipantThe first test of market placing orders, as opposed to MOC orders, on S&P, worked correctly. I tested on S&P just in case it turned out that IB wouldn’t allow us to carry the orders through to the close. Now we have discovered that they will as long as MOC orders are in place, but it was still a useful test. I am now about to test on the ASX. Also the new version of Batch Trader places a “1” in the Order Ref column. Should you use a second instance of the API it will place a “2” in the order ID so if you have a lot of trades in the markets from two systems you can tell them apart.
August 4, 2016 at 4:25 am #104937ScottMcNabParticipantMy version of MOC BatchTrader automatically places MOC order as soon as buy limit filled (fully). The time I enter is the time to cancel the remainded of partially filled orders and send MOC orders for the partial fills. The BatchTrader you are using would have hold all MOC (or sell at market) orders until the designated time Julian ?
August 4, 2016 at 6:39 am #104979JulianCohenParticipantScott McNab wrote:My version of MOC BatchTrader automatically places MOC order as soon as buy limit filled (fully). The time I enter is the time to cancel the remainded of partially filled orders and send MOC orders for the partial fills. The BatchTrader you are using would have hold all MOC (or sell at market) orders until the designated time Julian ?Mine does the same as yours Scott. If I choose to use Market orders to close the positions, then at the designated time it removes all unfilled orders and places a market order to sell. I do this 15 mins before the close of the ASX.
On a further note mine worked perfectly today on S&P and ASX. If IB will allow me to (I only switched to e RegT account yesterday) then I will place live orders on S&P tonight. Hooray for me!
August 4, 2016 at 6:55 am #104938ScottMcNabParticipantAhh…looked backed at pic..your version has an additional option to select MOC or market which my does not…for the US/AUS markets respectively I guess…so for the US markets it places sell order (MOC) immediately positions are filled but for AUS mkts it does not send sell(market) order until the same time it closes the unfilled positions ?
August 4, 2016 at 8:27 am #104980JulianCohenParticipantScott McNab wrote:Ahh…looked backed at pic..your version has an additional option to select MOC or market which my does not…for the US/AUS markets respectively I guess…so for the US markets it places sell order (MOC) immediately positions are filled but for AUS mkts it does not send sell(market) order until the same time it closes the unfilled positions ?Yup that’s it. When Len brought up what might have been a potential problem with trading MOC at higher leverage I tested the market orders on the S&P and it worked perfectly too. I didn’t bother with the closing auction on the ASX, it just places a market order 15mins before closing.
Nick any reason to not do that and use the closing auction?
-
AuthorPosts
- You must be logged in to reply to this topic.