I have my trading rule to short the index (or long put)
short = cross (MA50, MA10)
I expect to hold 5 days for my short position and close the short position. I dont know how to write it. please help.
I would like to do the backtesting, but it said i don't have buy/sell? please help