I am working on code for E-mini S&P. How can I limit the Buy and Short signals to 10 mins before market close?
TimeEnter = 055959; TimeQuit = 035559; tn = TimeNum(); TimeCross = Cross( tn, TimeQuit ); BeforeMarketClose = Cross( tn, 035559 ); Buy[j] = BuyStrategies[j]; Short[j] = ShortStrategies[j]; Sell[j] = Sell1[j] OR ShortStrategies[j] OR BeforeMarketClose[j]; Cover[j] = Cover1[j] OR BuyStrategies[j] OR BeforeMarketClose[j];
If I add tn[j] >= 075959 AND tn[j] < 035059 to the Buy and Short, then there will be no signals generated. How to solve it?