Spent the day updating an old MQL4 version of the nonLagMA and then translating it to MQL5 - and found this more concise MQL5 version here: "https://www.mql5.com/en/code/7022".
I have a question about Copy Buffer - in the MQL5 version attached, this line:
if(CopyBuffer(RawImahandle, 0, 0, to_copy, indiStruct[RAW_IMA_IDX].indiBuff)<0)
//int CopyBuffer( int indicator_handle, int buffer_num, int start_pos, int count, double buffer[] );
What does the buffer_num parameter refer to? I see in all code examples that I looked at today, it is always zero, and it does not work to put the destination buffer number (buffer index for the double buffer[] parameter) in it...
--- double buffer[] is described as "target array to copy", but seems to always be used as "target array for copying to" - is that correct (it is not the array being copied from)?
- www.mql5.com
Do not double post.
Your other topic has been removed.
I did press delete, and it didn't delete, so I edited that post to refer to here (the edit seemed to take just fine) - didn't know what else to do.
Still, no answer on what that zero means in CopyBuffer....
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
NonLagMA_v5:
This is a moving where effect of retardation is lessened by means of damped cosinusoid defining coefficients' ratios in equation of the linearly weighted average (LWMA).
Author: Nikolay Kositsin