rewrite ExponentialMovingAverage to SmoothedMovingAverage.