pylimma.tricube_moving_average

pylimma.tricube_moving_average(x, span=0.5, power=3)[source]

Moving average filter with tricube weights for a time series.

Port of R limma’s tricubeMovingAverage.

Parameters:
  • x (array_like) – 1-D series.

  • span (float, default 0.5) – Fraction of x to include in the smoothing window (clamped to (0, 1]; values <= 0 return x unchanged).

  • power (int, default 3) – Power applied to the tricube weights.

Returns:

Smoothed series of the same length as x.

Return type:

ndarray