I am trying to code an AFL where I get to know if today's candle has retested to a big candle (either green or red). So what I excatly want to know is, if todays high has touched any previous (60 days) big red candle upper half (for sell setup) but not pierced its high or if today's low has touched any previous (60 days) big green candle lower half, but not pierced its low.
A big candle is where absolute movement for the day is atleast 4% ( its on daily basis)
Here big candle means which have difference of atleast 5% between open and close
I want if another candle has retested to this big candle in a way if it has entered above midpoint of the big candle (high+low)/2.