hi, I wanted to check a simple code and browsing through the chart, I realized buy signals, that shouldn’t have been triggered and I don’t see why it happened anyway.
The following example is not a trading strategy, but simply to illustrate the buy signals.
The idea is: buy, if the current bar’s OPEN is higher than the level of 3/4 of last bar’s range (in the bullish 1/4 of the last bar)
for illustration purposes only, not an actual trading system
1
2
3
4
5
6
7
8
c1=Open>High[1]-((High[1]-Low[1])/4)
IFc1then
BUY2CONTRACTATMARKET
ENDIF
SET STOPpLOSS10
SET TARGETpPROFIT15
quickly back testing this on the DAX in the M30 time frame, I found cases where it worked as designed (case 1), but I also found examples (case 2) where c1 was not met, but a buy signal was triggered anyway.
We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.