I am trying to work out the back testing formula code for situation(s) where no signals are to be taken i.e. take no strategy action to go long or short – stay flat – do not do anything.
The scenario is as follows. I have two moving averages as a band (or envelope) say an eight period MA of the highs and a ten period MA of the lows. When the price bars are inside (between) the MA channels no trades are to be initiated – period. This will be the case irrespective of whatever is exhibited by any indicators.
How do I code the back test efs to not take any trading action and stay flat?
I have spent many hours searching through the forum but cannot see anything on this.
Can someone please help me.
Robert
The scenario is as follows. I have two moving averages as a band (or envelope) say an eight period MA of the highs and a ten period MA of the lows. When the price bars are inside (between) the MA channels no trades are to be initiated – period. This will be the case irrespective of whatever is exhibited by any indicators.
How do I code the back test efs to not take any trading action and stay flat?
I have spent many hours searching through the forum but cannot see anything on this.
Can someone please help me.
Robert
Comment