find_node_by_name {textAnnotatoR} | R Documentation |
Find node by name in a tree structure
Description
Recursively searches through a tree structure to find a node with a specific name. The search is performed depth-first and returns the first matching node found.
Usage
find_node_by_name(node, target_name)
Arguments
node |
Node object representing the current position in the tree. Should have:
|
target_name |
Character string specifying the name to search for |
Details
The function handles NULL inputs safely and performs a recursive depth-first search through the tree structure. It checks node names and recursively searches through child nodes.
Value
Node object if found, NULL otherwise
[Package textAnnotatoR version 0.1.4 Index]