Returns for tree intree an Nx1 vector B which is one if a given node is a branch point (more than 1 daughter node) and zero else.

TREES

Example:

>> B = B_tree (sample2_tree)'

[0, 0, 1, 0, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0]

>> sum (B)   → number of branch points

4

>> find (B)   → indices of branch points

[3, 6, 10, 12]

Creative Commons License
This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 License