I am writing a function in C++ to calculate the moving average of a data stream. I want to use incremental averaging . As am implementing this on a relatively weak microprocessor I want to perform a moving average. That is, I want to perform an incremental average over the last X values (X ~ 100).
As I understand it, incremental averaging requires all data to be averaged and does not support a moving window.
Does anyone know a good way to calculate the "moving" incremental average?