enstools.scores.kolmogorov_smirnov¶
- enstools.scores.kolmogorov_smirnov(reference: DataArray, target: DataArray, to_return='pvalue') Union[DataArray, Dataset]¶
Compute the KS statistic of the full domain and return the pvalue .
Relies on the two-sample Kolmogorov-Smirnov implementation from scipy.
- Parameters:
- referencexarray.DataArray
- targetxarray.DataArray
- to_return: str
Can select between ‘pvalue’, ‘statistic’ or ‘both’. In this last case it will return a dataset containing both variables as a DataArrays
- Returns:
- result: xarray.DataArray or xarray.Dataset
A data array with the time-series of the pvalue, statistic or a dataset with both time-series.