Need help with code in Pi

I was trying below code on Tatasteel eq 15 min chart. But it is generating alerts continuously. Can someone tell me what is wrong with the below or give other code-

Buy Script- RSI(CLOSE,9) =30

Buy Exit- RSI(CLOSE,9) = 80

Sell Script- RSI(CLOSE,9) =80

Sell Exit- RSI(CLOSE,9) =20

2 Likes

Phoenix, Can you try this?

Buy- CROSSOVER(RSI(CLOSE,9),30)

Sell- CROSSOVER(RSI(CLOSE,9),80)

Exit Long- CROSSOVER(RSI(CLOSE,9),80)

Exit Short- CROSSOVER(RSI(CLOSE,9),20)