31 #ifndef GRT_MOVING_AVERAGE_FILTER_HEADER
32 #define GRT_MOVING_AVERAGE_FILTER_HEADER
34 #include "../CoreModules/PreProcessing.h"
86 virtual bool process(
const VectorDouble &inputVector);
148 double filter(
const double x);
156 VectorDouble
filter(
const VectorDouble &x);
182 #endif //GRT_MOVING_AVERAGE_FILTER_HEADER
VectorDouble getFilteredData() const
virtual bool loadModelFromFile(string filename)
UINT filterSize
The size of the filter.
UINT getFilterSize() const
double filter(const double x)
virtual bool deepCopyFrom(const PreProcessing *preProcessing)
CircularBuffer< VectorDouble > dataBuffer
A buffer to store the previous N values, N = filterSize.
MovingAverageFilter & operator=(const MovingAverageFilter &rhs)
virtual bool saveModelToFile(string filename) const
UINT inputSampleCounter
A counter to keep track of the number of input samples.
MovingAverageFilter(UINT filterSize=5, UINT numDimensions=1)
virtual ~MovingAverageFilter()
virtual bool process(const VectorDouble &inputVector)