(cls, label, square, tree, children=())
return node(label, square, tree, children)
Construct the appropriate type of node from the given tree.
Construct the appropriate type of node from the given tree.
Construct the appropriate type of node from the given tree .
def from_tree(cls, label, square, tree, children=()):
        """Construct the appropriate type of node from the given tree."""
        if tree.domain.has_discrete_class:
            node = DiscreteTreeNode
        else:
            node = ContinuousTreeNode
        return node(label, square, tree, children)
def from_tree ( cls , label , square , tree , children = ( ) ) : if tree . domain . has_discrete_class : node = DiscreteTreeNode else : node = ContinuousTreeNode return node ( label , square , tree , children )