Close[i-1] -> GetClose(PERIOD_H1, i-1)

 
Hello,

Although indicators have access to multiple periods of data, I need to access bars with different periods. Is this possible with MQL 4?

Close[i-1] -> GetClose(PERIOD_H1, i-1)
Close[i-1] -> GetClose(PERIOD_M30, i-1)

Thanks
 
You can use iClose(), iOpen(), etc.

Btw, [i-1] is looking into the future.


Markus
 
It seems good. When a tick arrives, how much time does it take to update the data resource of "iClose()" function, possibly a physical file?

it seems Close[i] function is ready in memory and updated with an incoming tick very quickly. But the data that collected by iClose() will have some latency because of file update and flush times ?

Thanks.