intree must be BCT!!

At each branch point of tree intree, node values of Nx1 vector v get summed up in each sub-tree to Σ1 and Σ2. asym, an Nx1 vector, contains the ratio of Σ1 / (Σ1 + Σ2) for Σ1 < Σ2 at branch points (but NaN otherwise).


By default, number of terminal child nodes are compared in both sub-trees at a branch point: v is a vector of 1 when termination point and 0 else (see "T_tree"). For the example branch point on the right (at node 3), Σ1=2 terminals are divided by Σ1 + Σ2 = 2+3 terminals (= 0.4).


>> asym_tree (sample2_tree, T_tree (sample2_tree))'

[NaN, NaN, 0.4, NaN, NaN, 0.5, NaN, NaN, NaN, 0.3333, NaN, 0.5, NaN, NaN, NaN]

see demo movie with option '-m'

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