Closed
Description
Code Sample, a copy-pastable example if possible
input_ds = xarray.Dataset({'foo': ('x', [1, 2])}, {'x': [0, 1]})
input_ds.swap_dims({'x': 'z'})
Problem description
Currently this results in the error KeyError: 'z'
Expected Output
We now support dimensions without associated coordinate variables. So swap_dims()
should be able to create new dimensions (e.g., z
in this example) even if there isn't already a coordinate variable.
Metadata
Metadata
Assignees
Labels
No labels