User Tools

Site Tools


time-zones

Time-zones and Metatrader 4

When you are connected to a broker, it sends instrument pricing data to your MT4 terminal along with a time of when the price occurred. The time-zone of this time stamp is specific to the broker's server time. You can view the current server time of your broker in the 'Market Watch' window in MT4. To see this window, select View→Market Watch in MT4.

Your broker wont necessarily have a server time the same as the location they are situated. For reasons of convenience to their traders - such as conforming to the internationally recognised '5pm New York market close' - a broker can set their server time that is a familiar standard. Whatever time-zone the broker chooses, this means that all incoming price information is stamped with that time and stored within the MT4 historical databases.

Time-zones and EAs

When using an EA for trading, it is sometimes important to know what timezone the broker's server time is in. This is because some EAs are dependent on specific times where they are suited to trade. For example, some EAs may trade during the Asian session in order to capitalise on historically lower volatility. In order to restrict trading to the Asia session, the EA will have some logic to say “trade only between 11pm and 8pm GMT”. The problem is, however, your broker's server isn't necessarily specified in GMT. In order to allow the EA to determine the current time in GMT, the EA will often ask you to set a “GMT offset” parameter. This will allow the EA to adjust the time stamp it is receiving from your broker and convert (or “shift”) it into GMT time. Once it has done this, it can continue to use its standard GMT logic and work out when the Asia session is. A typical EA with GMT Offset parameters is shown below.

Time-zones and MT4 Exports

The most simplest way to create an MT4 Export is to just generate data in the GMT time-zone. When back-testing your EA, if it has a GMT Offset parameter, you will then need to set this to zero since the exported history file will not require any time-shift. NOTE: When you decide to run your EA live, make sure the GMT Offset parameter is correct for your broker's time. This is because when you trade live, the EA will be using the time stamp coming directly from your broker. If you wish to ensure your EA's settings are left unchanged in-between your back-testing and then running it live, you will need to set the “Time-zone” in the MT4 Export to that of your broker. This will ensure all the historical data time-stamps are shifted to match your broker's time-zone. Now when back-testing, you will need to set any “GMT Offset” parameter that your EA has into the correct setting for your broker.

Daylight Savings

Daylight savings adjustments are automatically done for timezones where it is applicable. If, for example, you select Eastern time (U.S. & Canada), timestamps will be adjusted during those dates/times where daylight savings was in-force.

For UTC/GMT time, note that if you wish to have a “pure” UTC time - that is, with no daylight savings applied (i.e. GMT Offset=0), then you should select “TC - Universal Coordinated Time or GMT - Monorovia, Reykjavik on Windows 7 or Windows XP respectively. Other UTC/GMT timezones such as London will automatically adjust for daylight savings.

time-zones.txt · Last modified: 2016/12/10 17:33 by tickstory