My algorithm submits a market buy order and then, 1 minute later, it cancels it if the order did not execute. In the vast majority of cases, the order does not execute. Why is that? Note that this is happening in the paper account, and I have not tried to live account.
See examples of submitted orders that my algorithm had to cancel one minute after submission in the table below. For the ones that I checked, the stock did trade during that minute.
I’ve had the same problem with limit orders, even though the stock traded for prices better than the order’s limit.
Symbol | Qty | Filled Qty | Side | Type | Time in Force | Limit Price | Stop Price | Filled Avg Price | Notional | Amount | Status | Fee | Source | Submitted at | Filled at | Canceled at | Replaced at |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
JAN | 520 | 0 | buy | market | gtc | - | - | - | - | $0.00 | canceled | 0.00 | access_key | 2023-03-15 14:48:00 | 2023-03-15 14:49:00 | ||
ESPR | 628 | 0 | buy | market | gtc | - | - | - | - | $0.00 | canceled | 0.00 | access_key | 2023-03-15 14:44:00 | 2023-03-15 14:45:00 | ||
ESPR | 869 | 0 | buy | market | gtc | - | - | - | - | $0.00 | canceled | 0.00 | access_key | 2023-03-15 13:59:00 | 2023-03-15 14:00:00 | ||
ESPR | 342 | 0 | buy | market | gtc | - | - | - | - | $0.00 | canceled | 0.00 | access_key | 2023-03-15 13:45:00 | 2023-03-15 13:46:00 | ||
LPSN | 142 | 0 | buy | market | gtc | - | - | - | - | $0.00 | canceled | 0.00 | access_key | 2023-03-15 13:32:00 | 2023-03-15 13:33:00 | ||
SIOX | 2631 | 0 | buy | market | gtc | - | - | - | - | $0.00 | canceled | 0.00 | access_key | 2023-03-15 13:28:00 | 2023-03-15 13:29:00 | ||
PACW | 87 | 0 | buy | market | gtc | - | - | - | - | $0.00 | canceled | 0.00 | access_key | 2023-03-15 13:13:00 | 2023-03-15 13:14:00 | ||
UVIX | 45 | 0 | buy | market | gtc | - | - | - | - | $0.00 | canceled | 0.00 | access_key | 2023-03-15 13:11:00 | 2023-03-15 13:11:00 | ||
FRC | 31 | 0 | buy | market | gtc | - | - | - | - | $0.00 | canceled | 0.00 | access_key | 2023-03-15 13:10:00 | 2023-03-15 13:11:00 | ||
PACW | 87 | 0 | buy | market | gtc | - | - | - | - | $0.00 | canceled | 0.00 | access_key | 2023-03-15 13:10:00 | 2023-03-15 13:11:00 |