| Bioinformatics Toolbox™ | ![]() |
[Matrix, ID, Distances] = getmatrix(PhytreeObj)
| PhytreeObj | phytree object created by phytree (object constructor). |
[Matrix, ID, Distances] = getmatrix(PhytreeObj) converts a phytree object, PhytreeObj, into a logical sparse matrix, Matrix, in which 1 indicates that a branch node (row index) is connected to its child (column index). The child can be either another branch node or a leaf node. ID is a column vector of strings listing the labels that correspond to the rows and columns of Matrix, with the labels from 1 to Number of Leaves being the leaf nodes, then the labels from Number of Leaves + 1 to Number of Leaves + Number of Branches being the branch nodes, and the label for the last branch node also being the root node. Distances is a column vector with one entry for every nonzero entry in Matrix traversed column-wise and representing the distance between the branch node and the child.
T = phytreeread('pf00002.tree')
[MATRIX, ID, DIST] = getmatrix(T);
Bioinformatics Toolbox functions: phytree (object constructor), phytreetool
Bioinformatics Toolbox object: phytree object
Bioinformatics Toolbox methods of phytree object: get, pdist, prune
![]() | getmatrix (geneont) | getnewickstr (phytree) | ![]() |
| © 1984-2008- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |