"PRICE_CLOSE" in Current bar is equal to...?

 

iMACD(NULL,0,MovingFast,MovingSlow,9,PRICE_CLOSE,MODE_MAIN,0);

if the bar is still the current one, how MT calculates the Price_close?? is that the last value?

The price_close is supposed to be the last value only when the bar is closed. right? Could that lead to problems?

Sorry if that sounds a partial "philosophical" question...:-)

Thanks.

 
xrafix:

iMACD(NULL,0,MovingFast,MovingSlow,9,PRICE_CLOSE,MODE_MAIN,0);

if the bar is still the current one, how MT calculates the Price_close?? is that the last value?

The price_close is supposed to be the last value only when the bar is closed. right? Could that lead to problems?

Sorry if that sounds a partial "philosophical" question...:-)

Thanks.

Close[0]=Bid

 
ggekko wrote >>

Close[0]=Bid

Thx but:

Based on what? Why not "Close[0]=Ask" ??

 
xrafix:

Thx but:

Based on what? Why not "Close[0]=Ask" ??

Ask=Bid+Spread

 

Hi xrafix

It can be a problem if your EA takes action on the basis of Close[0] because it does change with every new tick (i.e. Bid as ggekko said). If you want your EA to act on the last close, then use Close[1].

Cheers

Jellybean

 
Jellybean wrote >>

Hi xrafix

It can be a problem if your EA takes action on the basis of Close[0] because it does change with every new tick (i.e. Bid as ggekko said). If you want your EA to act on the last close, then use Close[1].

Cheers

Jellybean

Thank you!