Moving statistics

In this section, we will continue working on the Fisher River dataset. Moving or rolling statistics are computed by sliding a window of certain size over the original time series and aggregating the data for every window. This is also known as convolving over the time index. The two important parameters of the convolving operation are window size and stride length. The former defines the number of time units taken as input to the aggregate function while the latter sets the gap along the time index between every computation. For example, suppose a window size of k and stride of length l is used to compute the function f over a time series x1,x2, ... ,xn having N observations. In this scenario, the moving statistic is obtained ...

Get Practical Time-Series Analysis now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.