Recompose node.
Syntax
T = nodejoin(T,N)
T = nodejoin(T)
Description
nodejoin is a tree management utility.
T = nodejoin(T,N) returns the modified tree structure T corresponding to a recomposition of the node N.
The nodes are numbered from left to right and from top to bottom. The root index is 0.
T = nodejoin(T) is equivalent to T = nodejoin(T,0).
Examples
% Create binary tree of depth 3.
t = maketree(2,3);
% Plot tree structure t.
plottree(t)

% Merge nodes of indices 4 and 5.
tt = nodejoin(t,5);
tt = nodejoin(tt,4);
% Plot new tree structure tt.
plottree(tt)

See Also
maketree, nodesplt, wtreemgr
[ Previous | Help Desk | Next ]