mesmer.stats.lambda_function

mesmer.stats.lambda_function#

mesmer.stats.lambda_function(coeffs, local_yearly_T)#

Use logistic function to calculate lambda depending on the local yearly values. The function is defined as

\[\lambda = \frac{2}{\xi_0 + e^{\xi_1 \cdot T_y}}\]

It ranges between 0 and 2.

Parameters:
  • coeffs (ndarray of shape (2,)) – Coefficients for the logistic function. The first coefficient (\(\xi_0\)) controls the intercept, the second coefficient (\(\xi_1\)) controls the slope.

  • local_yearly_T (ndarray of shape (n_years,)) – Yearly values of one gridcell and month used as predictor for lambda.

Returns:

lambdas (ndarray of float of shape (n_years,)) – The parameters of the power transformation for each gridcell and month