Explanation to ewma and average calculation

Hi All,

i am searching for some more detailed explanation to the
ewma and average calculations in gnuradio.
There is something written at,
/usr/local/share/doc/gnuradio-3.2svn/html/classgr__peak__detector2__fb.html
So i think the average will only be calculated when the threshold does
find something.
However how is the average calculated ?
I can’t find any algorithm to that.

Any hint ?

Regards Markus