pyrtid.utils.means.get_mean_values_gradient_for_last_axis#
- pyrtid.utils.means.get_mean_values_gradient_for_last_axis(arr: ndarray[Any, dtype[float64]], mean_type: MeanType, weights: Optional[ndarray[Any, dtype[float64]]] = None) ndarray[Any, dtype[float64]][source]#
Get the mean values for the last axis of the input array.
- Parameters
arr (_type_) – Array of values with shape (nx, ny, nt) or (npts, nt).
mean_type (MeanType) – Type of mean chosen to average the simulated value when the observed one is defined over several grid cells of the domain.
weights (Optional[NDArrayFloat]) – Weights to apply
- Returns
Averaged values for the last axis.
- Return type
NDArrayFloat