It seems Moonshot is not trading based on the last row of the frame. Here the setup for the situation. I have the following order:
You see the submitted is at 18:11:09. I have noticed a consistency with order timing. The submit time of orders seems to happen a few seconds (5-15s) after the NEXT minute. So with this assumption, I converted the submit time to EST as I am working with US Stocks and checked my logs for 13:10:00 for that SID:
Which shows that my signal for that minute is 0.
So, I check 18:11:00 (13:11:00) just in case my assumption is wrong, which provides this frame:
Which still provides a 0 signal in the final row. Note though, that 13:10's signal did change between the minute. I know why this is happening. I am using alpaca's live data feed and not using minute aggregates. I am instead using the current price (I believe the field is last price) at the moment of trade. I am open to more precise ways to produce the current candle's price for intraday trading using alpaca if anyone has a better idea.
But this isn't my issue. My issue is why is quantrocket/Moonshot placing an order in this situation? It is my understanding that moonshot only uses the last row of the signals frame to dictate if an order should be placed. In this scenario, the last frame of the signal's data frame for both 13:10 and 13:11 was 0. Ergo, Quantrocket shouldn't have placed an order at all.
Open to thoughts on this. Please correct my assumptions if they are wrong.
Thanks in advance!