Returns for tree intree an Nx1 vector typeN
which attributes to each node either 0: termination, 1: continuation, 2: branch point.
If the tree is sorted
(see “sort_tree”),
this is the BCT string description of the topology of the tree
(see introduction section “BCT formalism”).
This function simply takes the vertical sum over the adjacency matrix
with 2 as an upper bound.
Examples:
>> typeN = typeN_tree (sample2_tree)'
[1, 1, 2, 1, 1, 2, 1, 0, 0, 2, 1, 2, 0, 0, 0]
>> typeN = typeN_tree (sample2_tree, '-bct')'
→ BCT string
CCBCCBCTTBCBTTT
This work is licensed under a
Creative Commons Attribution-Noncommercial-Share Alike 3.0 License