ewoksxas.fit.data.r2#

ewoksxas.fit.data.r2(observed, model)[source]#

Coefficient of determination of a model against the observed data.

Args:

observed: 1D array of observed y-values. model: 1D array of model y-values on the same grid.

Returns:

The R² value, or NaN when the observed data has zero variance.

Parameters:
  • observed (ndarray[tuple[int, ...], dtype[float64]])

  • model (ndarray[tuple[int, ...], dtype[float64]])

Return type:

float