Download MetaTrader 5
To add comments, please log in or register
They are already making profit using the Market. You can join them!
coolaid
97
coolaid 2014.07.28 03:31 

If you run the following you get back a time that is not on par with hour timeframe.

int n=iBarShift(NULL,PERIOD_M1,iTime(NULL,PERIOD_H1,2))-60;

Print(iTime(NULL,PERIOD_M1,n));

//Returned value equals something like 23:03

Also in chart, If you count 60 bars with crosshair(click and drag) from an hour interval like 22:00 on m1 time frame the time you get at the 60th bar is 23:03 and not 23:00.

There are 60 m1 bars between 22:00 and 23:00 not 63???

Keith Watford
Moderator
7904
Keith Watford 2014.07.28 05:33  

There are some bars missing on the M1 chart

Ie. there were no ticks for a period of more than 1 minute, so a bar was not formed. 

So between 22:00 and 23:00, 3 bars were missing , therefore only 57 bars in that 1 hour period.

So counting 60 bars from 22:00, takes you 3 bars past 23:00 

/
To add comments, please log in or register