How to change a EA based on tick to M1 values?

 
I have program a EA that works with tick information, but I would like to change to M1, M5, etc....

How do I have to proceed?

Regards,
 
In that case you will start to use the candle-based arrays such as Close[] and candle-based functions such as iClose.
The former will operate upon the timeframe of the current chart.
The latter will operate upon the timeframe you supply as a parameter in the function call.
And the tick will only be used to trigger your start() function.

CB
Reason: