EMA weight calculation - page 3

 
eddy >>:

ема=доля от клоз0 + "1-доля" от ема предыдущей

как это 1-доля?

EMA = 0.1*Close + (1-0.1)*EMAprevios; i.e. EMA=0.1*Close + 0.9*EMAprevios;

What is not clear here?

 
http://edu.finam.ru/showthread.php?t=516
 
EMA[i] = pr*Close[i] + EMA[i+1]*remainder of pr<br / translate="no">
pr=25.0/(1+period)
pr=25.0/(1+period) - where did it come from? The formula is different, with two instead of 25.
OK, here's the right formula for EMA, nonrecurrent - without any equivalent periods (as Svinozavr pointed out):

ema[i]=pr*Close[i] + (1-pr)*ema[i+1] =
pr*Close[i] + (1-pr)*(pr*Close[i+1] + (1-pr)*ema[i+2]) =
pr*Close[i] + pr*(1-pr)*Close[i+1] + (1-pr)^2*ema[i+2] =
pr*Close[i] + pr*(1-pr)*Close[i+1] + (1-pr)^2*(pr*Close[i+2] + (1-pr)*ema[i+3]) =
pr*Close[i] + pr*(1-pr)*Close[i+1] + pr*(1-pr)^2*Close[i+2] + (1-pr)^3*ema[i+3]) = ... =
pr*Sum( (1-pr)^(k-i) * Close[i+k] ; k = i..infinity)

Forget about the equivalent period, it's nonsense.
 
:)
Files:
mema.mq4  1 kb
 
i.e. the weight of the cloz is ten times less than the previous one, which is also ten times less than the previous yema, right? but then it's nothing at all, is it?
 
the most important thing i need to understand is what share in EM[i] all other clozes make up. i can't imagine any way.
 
I can't imagine an OBJECTIVE))
 
Well look at the last formula: ema[i] = pr*Sum( (1-pr)^(k-i) * Close[i+k] ; k = i..infinity)
The weight of each cloze decreases exponentially as it moves deeper into history, but still not very fast.
Let's say the weight of the first one is 0.2.
Then the second is 0.2*(1-0.2) = 0.2*0.8^1 = 0.16
the third is 0.2*0.8^2 = 0.128
the fourth is 0.2*0.8^3 = 0.1024 etc.
 
Can we speed it up?))
 
eddy >>:
т.е. вес клоза в десять раз меньше предыдущей, вес которой тоже в 10 раз меньше предыдущей ема, так? но ведь тогда он вообще ничтожен, разве нет?

For what is negligible? Well, output the EMA in the terminal by converting 0.1 to a period and see.

Or here, a rectangular signal with a period of 100 bars is smoothed by the EMA with coefficient 0.1: