Download MetaTrader 5

Question about the int "applied_price"

To add comments, please log in or register
Pierre DELAHAYE
72
Pierre DELAHAYE  

Good morning,

For the function iMA( string symbol, int timeframe, int period, int ma_shift, int ma_method, int applied_price, int shift).

If applied_price=PRICE_CLOSE, is iMA calculated on the close of the last candel or on the current price. ?
Indeed PRICE_CMOSE is it CLose[0] or CLose[1] ?

Thanks you

whroeder1
15304
whroeder1  
Trader55: iMA calculated on the close of the last candel or on the current price. ?

Both if you specify shift=0: SMA = ( Close[0] + Close[1] ... + Close[period-1] ) / period.

Pierre DELAHAYE
72
Pierre DELAHAYE  
Thanks a lot WHRoeder.
WHRoeder:

Both if you specify shift=0: SMA = ( Close[0] + Close[1] ... + Close[period-1] ) / period.

Thanks a lot WHRoeder.
To add comments, please log in or register