Added moving average for smoothing signal