Updates moving average code to remove use of numpy.

This is needed because numpy arrays cause issues with serialization.

@oxtopus please review
@breznak fyi - let me know if you see any issues