pastas.noisemodels.ArNoiseModel#

class pastas.noisemodels.ArNoiseModel(name: str = 'noise', norm: bool = True)#

Noise model with exponential decay of the residuals and weighting.

Parameters:
  • name (str, optional) – Name of the noise model. Default is “noise”.

  • norm (boolean, optional) – Boolean to indicate whether weights are normalized according to the Von Asmuth and Bierkens (2005) paper. Default is True.

Notes

Calculates the noise von Asmuth and Bierkens [2005] according to:

\[\begin{split}v(t_1) = r(t_1) - r(t_0) * \\exp(- \\Delta t / \\alpha)\end{split}\]

Calculates the weights as

\[\begin{split}w = 1 / \\sqrt{(1 - \\exp(-2 \\Delta t / \\alpha))}\end{split}\]

The units of the alpha parameter is always in days. The first value of the noise is the residual (\(v(t=0=r(t=0)\)). First weight is 1 / sig_residuals (i.e., delt = infty). Normalization of weights as in von Asmuth and Bierkens [2005], optional.

property nparam: int#

Return number of parameters for the noise model.

Returns:

Number of parameters (1 for ArNoiseModel).

Return type:

int

Methods#

set_init_parameters(→ None)

Set initial parameters for the noise model.

simulate(→ pandas.Series)

Simulate noise from the residuals.

weights(→ pandas.Series)

Calculate the weights for the noise.

get_correction(→ pandas.Series)

Get correction for a forecast using the noise model.

to_dict(→ dict)

Return a dict to store the noise model.