Currently working on easylanguage in Tradestation and use IBPlugin to submit trades to IB-TWS. For the most part everything is working well except for stocks priced under $5.00. When I submit the orders using easylanguage, the order attribute string looks correct but when the order reaches IB TWS and I check the API log, for some stocks it has increased the price to 4 decimals from 2 decimals which causes the order to be rejected. Can you please advise how I can fix this. Here are some additional details:
Stock testing with is: RIOT
Order attribute strings from Tradestation Easylanguage Print statements:
<++>
Contracts Found= 1.00 SET=STK#CUR=USD#SBL=RIOT#EXC=NASDAQ
conid=292830677.00 is RIOT order type is STPLMT
--- place BUY STPLMT order
uid STPLMT ATTR=#1007=SMART#53=BUY#6=STPLMT#22=0#1=6400#2=4.24#3=4.22
IB-API LOG MESSAGES (Trimmed for clarity)
12:19:40:587 <- 3-45-1879048959-292830677-RIOT-STK--0---SMART-NASDAQ-USD-RIOT-SCM---BUY-6400-STPLMT-4.24-4.2199-GTC
12:19:40:613 -> ---`4-2-1879048959-110-The price does not conform to the minimum price variation for this contract.-
As you can see, the 4.24 price is honored but the 4.22 price gets changed to 4.2199 which causes the error.
Best Regards,
Price problem using Tradestation & IBPlugin
-
- Site Admin
- Posts: 243
- Joined: Mon Apr 24, 2017 3:24 pm
Re: Price problem using Tradestation & IBPlugin
The RIOT contract receives a mintick of
0.0001
So
4.2199
is in line with that mintick.
However
4.22
should be aligned to
4.22
and not to
4.2199
even when mintick is 0.0001.
Rounding problem.
Solved in version 1515.
Just download from our public google folder.
https://drive.google.com/file/d/10oYHDP ... share_link
Before install, close all applications loading IBPlugin.
Run installation.
Try again.
0.0001
So
4.2199
is in line with that mintick.
However
4.22
should be aligned to
4.22
and not to
4.2199
even when mintick is 0.0001.
Rounding problem.
Solved in version 1515.
Just download from our public google folder.
https://drive.google.com/file/d/10oYHDP ... share_link
Before install, close all applications loading IBPlugin.
Run installation.
Try again.