I don't know how to code an EA for MT4, but there's a great EA called VHands which allows you to replay market action! Basically, you download the data for the pair, in the timeframe you want, and then control the speed of action. You can pause the data and put indicators on the chart as usual...