Backtest Syntax Help
SYMBOL CAT ACCOUNT 5000 COMMISSION 4.50 START_DATE 20210101 END_DATE 20230310 PIN DISPLAY DATE, OPEN, CLOSE, HIGH, LOW, VOLUME MFI (mf1, 14) # Use RSI and Candles RSI (rsi14, 14, 0) CANDLE (color, trend, patterns) # Buy if RSI is less than or equal to 35 and the Candle Pattern is Bullish Reversal BUYIF ( match('/R+/', patterns[0]) && rsi14[0] <= 35 ) THEN "Buy issued" # Sell if RSI is equal to or greater than 70 and the Candle Pattern is Bearish Reversal/Continuation SELLIF ( match('/R|C-/', patterns[0]) && rsi14[0] >= 70 ) THEN "Sell issued"