SuanShu, a Java numerical and statistical library

com.numericalmethod.suanshu.signalprocessing.filter
Class MovingAverageByExtension

java.lang.Object
  extended by com.numericalmethod.suanshu.signalprocessing.filter.MovingAverageByExtension
All Implemented Interfaces:
Filter

public class MovingAverageByExtension
extends java.lang.Object
implements Filter

This implements a Moving Average filter with these properties

Note that both past as well as future values are used in generating the outputs. Thus, be cautious to use this in a forecasting model.

When the filter length is even, more of the filter is forward in time than backward.


Constructor Summary
MovingAverageByExtension(double[] filter)
          Create a MovingAverageByExtension filter.
 
Method Summary
 double[] filtering(double[] Xt)
          Get the filtered signals.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MovingAverageByExtension

public MovingAverageByExtension(double[] filter)
Create a MovingAverageByExtension filter.

Parameters:
filter - the filter coefficients in reverse time order
Method Detail

filtering

public double[] filtering(double[] Xt)
Description copied from interface: Filter
Get the filtered signals.

Specified by:
filtering in interface Filter
Parameters:
Xt - the input signals
Returns:
the filtered signals

SuanShu, a Java numerical and statistical library

Copyright © 2011 Numerical Method Inc. Ltd. All Rights Reserved.