How can I fix my 4-hour time frame?

Hello,

My 4-hour time frame candles are not similar to the data in the MT5. Why is that? take a look at the below pics.
image
image

but the one-hour time frame is ok. Thanks in advance for your help.

Best regards,

Hi Simon,

The first thing I can think of is the fact that there is a timeshift that needs to be applied, like your 4-hours candles are not aligned to 4-hour marks. For example, the first 4-hour candle of a day starts at 22:00 and ends at 1:59, rather than starting at 0:00 and ending at 3:59. That's the case for MT4 brokers for which the market opening time is not 00:00 Monday, but rather 22:00 Sunday, i.e. they run on a -2 hours shift.

One way to verify if that is the case is to check the 1H bars, compare what your AB says for OHLC and what MT5 says.

If that is the problem, then you can adjust your time shift in the database settings (see https://www.amibroker.com/guide/w_dbsettings.html for more details). Of course, that assumes that what you imported already all have the same timeshift. If some symbols have -2 hours, other 0 hours, and other 1 hour, then it won't work. You can explore the data you already imported into AB with Quote Editor (under the Symbol menu).

2 Likes

Thank you very much. I could fix it.

I'm very glad to hear that! :wink:

1 Like