Read phylogenetic tree file
Tree
= phytreeread(File
)
[Tree
, Boot
]=
phytreeread(File
)
File | Character vector or string specifying a Newick- or Nexus-formatted tree file (ASCII text file) name, a path and file name, or a URL pointing to a file. For the
Nexus tree format, only one tree from the first |
Tree |
|
Boot | Column vector of bootstrap values
for each tree node specified in
|
reads
a Newick- or Nexus-formatted tree file and returns a phytree object containing
data from the file.Tree
= phytreeread(File
)
The NEWICK tree format can be found at:
The NEXUS tree format can be found at:
Note
This implementation allows only binary trees. Non-binary trees are translated into a binary tree with extra branches of length 0.
[
returns Tree
, Boot
]=
phytreeread(File
)Boot
,
a column vector of bootstrap values for each tree node specified in File
.
If File
does not specify a bootstrap value
for a node, it returns a NaN value for that node. phytreeread
considers
the following values in File
to be bootstrap
values:
Values within square brackets ([]
)
after the branch or leaf node lengths (for Newick-formatted trees
only)
Values that appear instead of branch or leaf node labels (for both Newick- and Nexus-formatted trees)
tr = phytreeread('pf00002.tree')
Phylogenetic tree object with 33 leaves (32 branches)
tr2 = phytreeread('pf00002.nex')
Phylogenetic tree object with 33 leaves (32 branches)