neat.MorphTree.convert_node_arg_to_nodes¶
- MorphTree.convert_node_arg_to_nodes(node_arg)[source]¶
Converts a node argument to a list of nodes. Behaviour depends on the type of argument.
- Parameters:
node_arg (
None, neat.MorphNode, {‘apical’, ‘basal’, ‘axonal’, ‘somatic’} or iterable collection of instances of neat.MorphNode) –None: returns all nodes
neat.MorphNode: returns list of nodes in the subtree of the given node
{‘apical’, ‘basal’, ‘axonal’}: returns list of nodes in the apical, basal or axonal subtree
- iterable collection of neat.MorphNode: returns the same list of nodes
If an iterable collection of original nodes is given, and the computational tree is active, a reduced list is returned where only the corresponding computational nodes are included. If an iterable collection of computational nodes is given, and the original tree is active, a list of corresponding original nodes is given, but the in between nodes are not added.
- Return type:
list of neat.MorphNode