there’s the full code
on the backtest over 20 days, it is only taking 8 trades, i want it to take a trade every candle, which is 1 hour
// Definition of code parameters
DEFPARAM CumulateOrders = False // Cumulating positions deactivated
// Prevents the system from placing new orders on specified days of the week
daysForbiddenEntry = OpenDayOfWeek = 6 OR OpenDayOfWeek = 0
// Conditions to enter long positions
c1 = (Close[1] < Close[2])
IF c1 AND not daysForbiddenEntry THEN
BUY 1 CONTRACT AT MARKET
ENDIF
//Conditions to exit long positions
c2 = ((TRADEPRICE/Close[1])-1) > 0.006
c3 = ((TRADEPRICE/Close[1])-1) > -0.004
IF c2 or c3 THEN
SELL AT MARKET
ENDIF
// Conditions to enter short positions
c4 = (Close[1] > Close[2])
IF c4 AND not daysForbiddenEntry THEN
SELLSHORT 1 CONTRACT AT MARKET
ENDIF
// Conditions to exit short positions
c5 = ((TRADEPRICE/Close[1])-1) > 0.006
c6 = ((TRADEPRICE/Close[1])-1) > -0.004
IF c5 or c6 THEN
EXITSHORT AT MARKET
ENDIF