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
The string and rich representations of Dataset and DataArrays are standardized. However, the DataTrees can become pretty complex structurally (unlike DataArrays and Dataset). Hence, adding visualizations capabilities to summarize would be helpful, like the pandas describe method, that summarizes a DataFrame.
Describing the DataTree can be a lite-weight string representation focusing on the structure of the tree only without the contents.
defempty_datatree_structure(xdt: dt.DataTree) ->dt.DataTree:
# Print an empty datatree from a full structure (like a tree command)returndt.DataTree.from_dict({k.path: Noneforkinxdt.leaves})
empty_datatree_structure(loaded_xdt)
Is your feature request related to a problem?
The string and rich representations of Dataset and DataArrays are standardized. However, the DataTrees can become pretty complex structurally (unlike DataArrays and Dataset). Hence, adding visualizations capabilities to summarize would be helpful, like the pandas describe method, that summarizes a DataFrame.
Describing the DataTree can be a lite-weight string representation focusing on the structure of the tree only without the contents.
Describe the solution you'd like
Here is some code I used to achieve that goal:
Describe alternatives you've considered
No response
Additional context
Issue content taken from xarray-contrib/datatree#334
The text was updated successfully, but these errors were encountered: