Open aFarchi opened 2 hours ago
Thanks for opening your first issue here at xarray! Be sure to follow the issue template! If you have an idea for a solution, we would really welcome a Pull Request with proposed changes. See the Contributing Guide for more. It may take us a while to respond here, but we really value your contribution. Contributors like you help make xarray better. Thank you!
What is your issue?
Hello,
I am trying to stack/unstack a dataset. According to the doc, I am supposed to recover the original dataset, but this is not what I observe.
Stacking the dataset looks correct:
But unstacking seems incorrect:
var_a
should have dimensions(sample, dim_a)
andvar_b
should have(sample, dim_b)
.The issue seems even worse when
len(dim_a)>1
:Could it be related to the
level
argument ofto_unstacked_dataset()
?Note that I have been using the last version for this test: