From bb3b9549d0ffd21b32b75f8577062a05bc78ffa2 Mon Sep 17 00:00:00 2001 From: Jordi Date: Fri, 19 Jan 2024 19:35:53 +0100 Subject: [PATCH] cosmetics --- ete4/core/tree.pyx | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/ete4/core/tree.pyx b/ete4/core/tree.pyx index e170b098..a9bae819 100644 --- a/ete4/core/tree.pyx +++ b/ete4/core/tree.pyx @@ -273,7 +273,7 @@ cdef class Tree(object): self._collapsed_faces = value def __bool__(self): - # If this is not defined, bool(t) will call len(t). + # If this is not defined, bool(t) will call len(t) (terribly slow!). return True def __repr__(self): @@ -457,16 +457,12 @@ cdef class Tree(object): return self.up.add_child(child=sister, name=name, dist=dist) def remove_sister(self, sister=None): - """Remove a sister node. + """Remove a sister node and return it. - It has the same effect as self.up.remove_child(sister). - - If a sister node is not supplied, the first sister will be deleted - and returned. + It has the same effect as self.up.remove_child(sister). If a sister + node is not supplied, the first sister will be deleted. :param sister: A node instance to be removed as a sister. - - :return: The node removed. """ sisters = self.get_sisters() if not sisters: