You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, it is a nice package. Just want to know if the bins parameter can be time-varying. Or more flexible, can the bins parameter be also a xarray.DataArray? I find that xhistogram at here cannot accept xarray.DataArray as its bin argument.
The text was updated successfully, but these errors were encountered:
Hi, thanks!
I hadn't thought of time-varying bins, but I can see it implemented without too much trouble.
As for accepting xarray.DataArray for the bins argument, it is also feasible (I guess it would be a good idea to make it mandatory for time-varying bins).
This needs some refactoring so that the code stays clean but right now I don't see anything impossible. That would be nice since it seems from this comment that it won't be implemented in xhistogram before a while. I will work on that as soon as I have a solid base package (in a few days hopefully).
That's a good news. I have to calculate PDF of a tracer field between min and max values and these values change with time (or even with depth). So I am expecting this behavior or similar:
# tracer[T, Z, Y, X] is a 4D variablehist=xh.histogram(tracer, bins=[tracer.min(['X', 'Y']), tracer.max(['X', 'Y'])], dims=['X', 'Y'])
# output hist[T, Z, PDF] should be 3D variable
xhistogram cannot accept xarray as its bins argument because it relies on numpy. In addition, it does not support dask well. Looking forward to your solutions. I guess the bins argument accepting xarray.DataArray would be a very good point for your release.
Hi, it is a nice package. Just want to know if the
bins
parameter can be time-varying. Or more flexible, can thebins
parameter be also axarray.DataArray
? I find thatxhistogram
at here cannot acceptxarray.DataArray
as itsbin
argument.The text was updated successfully, but these errors were encountered: