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
* Add DataTree.is_data_empty property and .prune() method │
│ │
│ - Add is_data_empty property to check if node contains data variables with actual data │
│ - Add prune() method to remove empty nodes while preserving tree structure │
│ - Include comprehensive tests covering basic pruning, intermediate nodes, and filtering scenarios │
│ - Useful for cleaning up DataTree after time-based filtering operations
* documenting changes in whats-new.rst file
* removing blank lines
* removing new property instead using data_vars and fixing corresponding test
* removing .is_empty_data entry
* updating github url
* fixing test accordingly
* fixing doctest
* fixing doctest
* fixing doctest
* replacing doctest
* replacing doctest
* removing empty line
* removing empty line
* Update xarray/core/datatree.py
Co-authored-by: Tom Nicholas <tom@earthmover.io>
* Update xarray/core/datatree.py
Co-authored-by: Tom Nicholas <tom@earthmover.io>
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* improving doctests
* fixing typo
* refactoring test accodingly to Tom's suggestion
* fixing test_prune_after_filtering
* refactoring test to use assert_identical
* refactoring test to use assert)_equal
* adding reference to .prune method in Subsetting Tree Nodes
* adding # doctest: +NORMALIZE_WHITESPACE to avoid error with trailing space
* Fix doctest trailing space issue in prune method
* trial 2 fixing trailing space
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* normalizing whitespace for doctest
* normalizing whitespace and adding ellipsis for doctest
* normalizing whitespace and adding ellipsis for doctest
* normalizing whitespace and adding ellipsis for doctest
---------
Co-authored-by: Tom Nicholas <tom@earthmover.io>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
0 commit comments