wind_validation.hist.metrics.emd

wind_validation.hist.metrics.emd(hist1, hist2, dim=None)[source]

Calculates the Earth Movers Distance (EMD) between two xarray.DataArrays’s containing pywasp wind histogram’s

Parameters
  • hist1 (xarray.DataArray) – PyWAsP-formatted Wind Histograms

  • hist2 (xarray.DataArray) – PyWAsP-formatted Wind Histograms

  • dim (str or None, optional) – The dimension to calculate the EMD over, options are: “wsbin” and “sector” and None (the default), which calculates the 2D EMD in U,V-space If “sector” is chosen, the shortest circular distance between bins is used.

Returns

Earth Movers Distance the histograms

Return type

xarray.DataArray