In a nutshell: Once buy condition is true, stay true until selling condition is true, even if buy condition becomes false in between.
Basically I'm using 2 ema strategy and want to display only stoploss ema
maSmall = ta.ema(low, 50) //1st 50 ema with low as source
maLarge = ta.ema(high, 50) //2nd 50 ema with high as source
buyCondition = close > maLarge
shortCondition = close < maSmall
Basically I want buyCondition to stay true until shortCondition become true.
But when price is in between both ema my buyCondition on currrent candle becomes false.
I don't want it to let it happen and want buyCondition to become false only when close < maSmall.
Note: I'll use these condition in color variable when plotting the ema's