Why buy/sell orders are not issued
-
Firs of all thank you for the awesome library, gret job done!
I'm studying an example with SmaCross strategy from library. I use 10000$ investment cash and PercentSizer = 100 on TSLA stock . What I notice is that at some crossovers the buy order is not issued even though there's enough available cash, please see pic below where the courser is.
If I reduce the PercentSizer to 95, buy/sell orders seems fine. If I understand the sizer well (by def: This sizer returns percents of available cash), there's enough cash to buy many stocks at that point, so why the buy order is not issued?
-
Since nothing is shown except the diagram, here ia the guess - 100% size was calculated based on the bar close price and order issued. Next bar open price was higher, therefore it was not enough cash to by the size and order was cancelled.
-
@ab_trader Thank you, that answers the question.
-
@ab_trader Could this still be a problem if set_coc is set to True? Thanks.
-
@Eduardo-De-La-Garza I don't think so.