Previous topic

scikits.timeseries.lib.moving_funcs.mov_min

Next topic

scikits.timeseries.lib.moving_funcs.mov_sum

This Page

scikits.timeseries.lib.moving_funcs.mov_std

mov_std(data, span, dtype=None, ddof=0)

Calculates the moving standard deviation of a 1-D array.

Parameters:

data : array-like

Input data, as a sequence or (subclass of) ndarray. Masked arrays and TimeSeries objects are also accepted. The input array should be 1D or 2D at most. If the input array is 2D, the function is applied on each column.

span : int

Size of the filtering window.

dtype : dtype, optional

Data type of the result.

ddof : {0, integer}, optional

Means Delta Degrees of Freedom. The divisor used in calculations of variance or standard deviation is N-ddof. For biased estimates of the variance/standard deviation, use ddof=0. For unbiased estimates, use ddof=1.

Returns:

result :

The result is always a masked array (preserves subclass attributes). The result at index i uses values from [i-span:i+1], and will be masked for the first span values. The result will also be masked at i if any of the input values in the slice [i-span:i+1] are masked.