Coding help - page 165

 

hi mladen,

may i know why this attached mq4 still not work? i just want to have these functions within it plus mtf & non repaint, no more. Thanks.

Files:
 
kenwa:
hi mladen, may i know why this attached mq4 still not work? i just want to have these functions within it plus mtf & non repaint, no more. Thanks.

iMAOnArray() means that it should use an array for source data (iCCI () is not an array, it is a function that return a result for a desired bar)

_________________________

[TR]

[TD]ma_shift [TD] - [TD="width: 100%"]MA shift

[TR]

[TD]ma_method [TD] - [TD="width: 100%"]MA method. It can be any of the Moving Average method enumeration value.

[TR]

[TD]shift [TD] - [TD="width: 100%"]Index of the value taken from the indicator buffer (shift relative to the current bar the given amount of periods ago).
[/TD] double iMAOnArray(double array[], int total, int period, int ma_shift, int ma_method, int shift)

[/TD]

[/TR]

[/TABLE]

Calculation of the Moving Average on data stored in a numeric array. Unlike iMA(...), the iMAOnArray function does not take data by symbol name, timeframe, the applied price. The price data must be previously prepared. The indicator is calculated from left to right. To access to the array elements as to a series array (i.e., from right to left), one has to use the ArraySetAsSeries function. Parameters:

[TABLE="class: docparams"]

array[][/TD] -[/TD] Array with data.[/TD]

[/TR]

total[/TD] -[/TD] The number of items to be counted. 0 means whole array.[/TD]

[/TR]

period[/TD] -[/TD] [TD="width: 100%"]Averaging period for calculation.
 

mladen, i think it is up to my best ability as this attachment already, still not work, i just want the 3 cases functions within, within same indicator + mtf. hope you could help.

 
kenwa:
mladen, i think it is up to my best ability as this attachment already, still not work, i just want the 3 cases functions within, within same indicator + mtf. hope you could help.

You are trying to use 6 buffers and you declared only 3 as buffers (using SetIndexBuffer() for that)

 
mladen:
You are trying to use 6 buffers and you declared only 3 as buffers (using SetIndexBuffer() for that)

mladen:

hi again, but i actually do not want to show the unsmooth idt signal line, if i include in the indexbuffers, it will occupy 8 limited buffer seats? how to solve? i attached the amended one with some mild issues there, i think i can only do this version up to my limited ability, and it is also what i want it to do, (i.e. allow 3 cases within one indicator), but because there are three idt buffers occupied , make me cannot extend more symbols to 5 or more, (all the idt buffer are waste or occupy the 8 limited buffer reserve) do you have any good suggestions how to improve? thanks for advice.

 
kenwa:
mladen: hi again, but i actually do not want to show the unsmooth idt signal line, if i include in the indexbuffers, it will occupy 8 limited buffer seats? how to solve? i attached the amended one with some mild issues there, i think i can only do this version up to my limited ability, and it is also what i want it to do, (i.e. allow 3 cases within one indicator), but because there are three idt buffers occupied , make me cannot extend more symbols to 5 or more, (all the idt buffer are waste or occupy the 8 limited buffer reserve) do you have any good suggestions how to improve? thanks for advice.

For that you can take a look at the indicator posted here : https://www.mql5.com/en/forum/174385/page109 (as it is said there, it is an indicator that can display 8 different smoothed cci values of 8 different symbols also being a non repainting multi time frame indicator. That is one way how it can be done). Or write your own smoothing functions (but still you will have to do the same -or very similar - to make it non-repainting and multi time frame)

 

Hi Mladen

I know that you're in flood with requests from many members at present, still hope my request is at somewhere on your list

Thanks for all, inspired Mladen !

fareastol

 

Custom indicator causing Mt4 platform to dramatically open slower.

I've been using this indicator for some time now. I noticed when initially opening up the Mt4 platform it is slow to load. Under the "Experts" tab I noticed the same error message for every chart that it is loaded on:

CustomCandle6 USDJPY,M15: invalid time value for ObjectMove function.

Can someone explain and/or correct this?

Files:
 

hello mladen

Yes, i know that's a very good & design indicator, just is not exactly my intent functions only ( i want 3 cases can be done within the same indicator). and my knowledge and ability also cannot allow me to modify your highly advanced code to suit my need.

i do a new test version 3 attached here, may be further one step little improve to my test version 2 before, could you please check is it ok? will this attached version arrangement cause repaint past problem? by the way, i do not know why has repaint issue, is it due to the code of: int i,limit,counted_bars=IndicatorCounted();//----

limit=Bars-counted_bars;

for(i=0;i<limit;i++)

while yours is int i,counted_bars=IndicatorCounted();

if(counted_bars<0) return(-1);

if(counted_bars>0) counted_bars--;

int limit = MathMin(Bars-counted_bars,Bars-1);

for(i=limit;i>=0;i--) ??

If this attached version three is ok and not cause repaint, could you kindly help me to convert it to mtf version,(i do not know how to modify or copy & paste your previous mtf to fit this version. i will do all the rest. if this attached version is not ok or cause repaint, may be please help me convert #1645 (above) version 2 to mtf, many thanks.

 
daytrade5:
I've been using this indicator for some time now. I noticed when initially opening up the Mt4 platform it is slow to load. Under the "Experts" tab I noticed the same error message for every chart that it is loaded on:

CustomCandle6 USDJPY,M15: invalid time value for ObjectMove function.

Can someone explain and/or correct this?

Try to use the one from this post : https://www.mql5.com/en/forum/173574/page292

Reason: