Zerodha PI code creation

Need help to create code for zerodha PI.

If RSI 14 crossed over EMA 21 then buy
If RSI 14 crossed below EMA 21 then sell

now you can create & backtest technical analysis using streak, login to

1 Like

Respected Sir,
Please provide the out required.

Checked streak but it is not solving my purpose.

I have written code but my problem in PI when condition is fulfilled it do not highlight the stock in yellow which it normally do when condition is matched

following is the code

I hope you will understand the situation and help me out

I guess it is not possible as per my logic.

Since RSI of 14 days is value (0 to 100) and EMA is the stock price.
you are going to create unrealistic strategy.