Moving Average - Heisenberg0203/GETS GitHub Wiki
Moving Average (MA) takes the mean of several historical observations to predict future values. The forecaster uses data from the current period to previous N observation depending on the window width. The varying pattern in the time series data affects the width of the window and the amount of smoothing required to make predictions.
forecastt+k = (Wt-1 + Wt-2 + Wt-3 + .... Wt-n) /N
The grammar for Moving Average is shown in where <window_var> generates the width of the window and <lag_var> generates the lag in time series which is implemented using the shift function provided in Python’s Pandas library to forecast by substituting parameters in the above equation.
python ponyge.py --parameters gets/sma.txt
By default it runs on Daily Waste Generated dataset. Command to run on the custom dataset:
python ponyge.py --parameters gets/sma.txt --dataset_train path_to_traindataset --dataset_test path_to_testdataset
.