Help with EA analyzing previous bars

 

Like in the iHighest and iLowest where it can scan the last 100 or however much bars you designate, how do i make my EA or Indicator i've made to analyze previous bars as well.

 I've seen it done in a pattern recognition indicator where it plots hammers, shooting stars, etc... on previous candles as well as forward scanning live candles.

So far i've only made my EA be able to detect desirable conditions moving forward, how would i also let it detect conditions of lets say 100 bars backwards to plot objects on the chart?

 

Does it have something to do with shift? If so can someone provide the code or the concept to form the code i'll be thankful

 
Click on TA above and lI believe that you can find the code for fractals, that will give a simple example of checking for a pattern
 
Got it, Thank you GumRai
Reason: