Missing Alerts to trigger order in Streaming mode
Author: gregChen
Creation Date: 5/29/2020 3:59 PM
profile picture

gregChen

#1
Observed multiple times there are missing alerts to trigger order in stream mode ( Fidelity stream, 1 m, TQQQ and SQQQ pair)

Trades generated by a strategy:
Long TQQQ 217 5/29/2020 11:27 79.42 5/29/2020 11:31 79.42 0 $0.00 5 $0.00 Short to Long Buy Short -0.2 0.3
Long SQQQ 1,756 5/29/2020 11:31 9.848 5/29/2020 11:35 9.84 -0.08 ($13.70) 5 ($2.74) Long to Short Buy Long -0.18 0.58
Long TQQQ 217 5/29/2020 11:35 79.438 5/29/2020 11:43 79.685 0.31 $53.51 9 $5.95 Short to Long Buy Short -0.3 0.47

Actual Orders auto-placed from alerts

PaperAccount1 5/29/2020 11:26 Filled TQQQ Buy Market 218
PaperAccount1 5/29/2020 11:34 Filled TQQQ Buy Market 218
PaperAccount1 5/29/2020 11:42 Filled TQQQ Sell Market 436


There are three alerts missing ( sell TQQQ at 5/29/2020 11:31, buy SQQQ at 5/29/2020 11:31 and sell 5/29/2020 11:35). However portfolio-sync allows to sell TQQQ one time.

Please help to advise how to handle this case?

Thanks

Greg
profile picture

Eugene

#2
If you wish to troubleshoot this, the most important and missing pieces are:

1) your strategy code,
2) data loading + position sizing settings,
3) Wealth-Lab's preferences (Backtest, Slippage, Advanced and Trading).
profile picture

gregChen

#3
Do we have stream simulator to debug?
profile picture

Eugene

#4
Let's not get sidetracked.

And since you're apparently trading a pairs strategy in Streaming mode, here's what you need to know as employment notes: Choosing optimal trading tool: Strategy Monitor or Strategy window
profile picture

gregChen

#5
Eugene,

Great information. The missing alerts occurred randomly.

Since SellAtMarket for stock 1 and BuyAtMarket for stock 2 at the same coming bar, needs to have a routine to makes sure that the secondary data is available.

Thanks a lot.
profile picture

Eugene

#6
At your service.
This website uses cookies to improve your experience. We'll assume you're ok with that, but you can opt-out if you wish (Read more).