Added simple moving average algorithm