Max Enrik: I just need to Draw one of latest " Arrow ", no need to draw ten thousand Arrow on my chart.
No need to not draw them. What are you going to do when new bars form? Go back and delete the old ones? After the first run you are only going to be processing bar zero anyway. See How to do your lookbacks correctly.
No need to not draw them. What are you going to do when new bars form? Go back and delete the old ones? After the first run you are only going to be processing bar zero anyway. See How to do your lookbacks correctly.
OMG! Why I do not use that great example just for my this concern. ( even I used that great example for my other issues )
Please let me what could I write for lookback.
int lookback = ?; // I do not know what could I write here.for(int i = Bars-1-MathMax(lookback, prev_calculated); i >= 0; --i)
{
bufferOne[i]=iMA(Symbol(),0,26,0,MODE_EMA,PRICE_CLOSE,i);
bufferTwo[i]=bufferOne[i+1];
}
int lookback = ?; // I do not know what could I write here.for(int i = Bars-1-MathMax(lookback, prev_calculated); i >= 0; --i)
{
bufferOne[i]=iMA(Symbol(),0,26,0,MODE_EMA,PRICE_CLOSE,i);
bufferTwo[i]=bufferOne[i+1];
Did you read the link provided? Look again at the very first box:
int lookback = ... // iMA(period) has look back of period.// buffer[i+2] has look back of 2 (as TimeSeries)// buffer[i-2] has look back of 2 (not TimeSeries)// use maximum of all.
You have 26 for the iMA and 1 for the [i+1]. What do you think the maximum is?
Did you read the link provided? Look again at the very first box:
You have 26 for the iMA and 1 for the [i+1]. What do you think the maximum is?
Of course, I already read and I tried your great example, I did not get good results that is why I asked about that. Since your previous comment I try new indicator just for try your example. I hope I will do something good separately ( then I will combine them ).
( if I won't get good results I will post whole code )
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
Thanks a lot.
#Only One Draw Arrow - Closed
Answer is: No need to draw " Arrows " by the DRAW_ARROW, need to draw objects at the condition.
#Buffer ( array out of range in ) - Open
I try below code and it gives me fatal error: " array out of range in ", am I doing wrong? If yes, then how can I solve it, please?
Thanks in advance.
OMG! Why I do not use that great example just for my this concern. ( even I used that great example for my other issues )
Please let me what could I write for lookback.
Of course, I already read and I tried your great example, I did not get good results that is why I asked about that.
Since your previous comment I try new indicator just for try your example. I hope I will do something good separately ( then I will combine them ).
( if I won't get good results I will post whole code )
Thanks a lot.
Haha! Thanks a lot Mr. William. What a wonderful results. Awesome! Huge thanks!
I use OnCalculate() with " int " now I need to ask, which is good for this type of indicators, int or void, please?
Thanks in advance.