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
Initializing a DataArray from a scalar along with non-scalar coords and dims, which was implemented in #3159, does not extend to Datasets. Initializing multiple DataArrays with shared dimensions, as a Dataset, is not similarly possible.
Describe the solution you'd like
Dataset creation and assignment could handle scalar values in the same way as DataArray creation.
Only the first case easily extends to multiple variables sharing x.
Describe alternatives you've considered
Defining Coordinates in advance is the currently working alternative, but it's not as elegant and is a rare case of needing to explicitly define a Coordinates instance.
Additional context
If this enhancement is supported, I would attempt a PR.
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem?
Initializing a DataArray from a scalar along with non-scalar coords and dims, which was implemented in #3159, does not extend to Datasets. Initializing multiple DataArrays with shared dimensions, as a Dataset, is not similarly possible.
Describe the solution you'd like
Dataset creation and assignment could handle scalar values in the same way as DataArray creation.
For example
could yield the same thing as
Only the first case easily extends to multiple variables sharing
x
.Describe alternatives you've considered
Defining Coordinates in advance is the currently working alternative, but it's not as elegant and is a rare case of needing to explicitly define a Coordinates instance.
Additional context
If this enhancement is supported, I would attempt a PR.
The text was updated successfully, but these errors were encountered: