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
When e.g. creating a Dataset from multiple DataArrays that are supposed to share the same grid, but are not exactly aligned (as is often the case with floating point coordinates), we usually end up with undesirable NaNs inserted in the data set.
For instance, consider the following data arrays that are not exactly aligned:
I think this is a frequent enough situation that we would like a function to re-align all the data arrays together. There is a reindex_like method, which accepts a tolerance, but calling it successively on every data array, like so:
When e.g. creating a
Dataset
from multipleDataArray
s that are supposed to share the same grid, but are not exactly aligned (as is often the case with floating point coordinates), we usually end up with undesirableNaN
s inserted in the data set.For instance, consider the following data arrays that are not exactly aligned:
They show gaps when combined in a data set:
I think this is a frequent enough situation that we would like a function to re-align all the data arrays together. There is a
reindex_like
method, which accepts a tolerance, but calling it successively on every data array, like so:would result in the intersection of the coordinates, rather than their union. What I would like is a function like the following:
I have not found something equivalent. If you think this is worth it, I could try and send a PR to implement such a feature.
The text was updated successfully, but these errors were encountered: