+0  
 
+1
1849
1
avatar

how to calculate 5 point moving average

 Mar 24, 2017
 #1
avatar+33657 
+1

Something like:

 

xavnew = xavold + (xi+1 - xi-5)/5

 

This assumes your first xav is based on the first five values of x, and that i is an index that points to the 5th value of the current value of xav, just prior to calculating the next value.

.

 Mar 24, 2017

0 Online Users