read.nexus(file, tree.names = NULL)
NULL
(the default), the trees are named "tree1"
,
"tree2"
, ..."phylo"
with the following components:"-1"
), and the tips are represented with
positive numbers. For each row, the first column gives the
ancestor. This representation allows an easy manipulation of the
tree, particularly if it is rooted.edge
.edge
.NULL
if not available in the file).NULL
otherwise).c("phylo", "multi.tree")
, and is a list of objects of class
"phylo"
.
An attribute "origin"
is further given to the returned object
which gives the name of the source file (with its path). This is used
to write a tree in a NEXUS file where all the original data must be
written (not only the tree) in accordance to the specifications of
Maddison et al. (1997).read.dna
,
read.table
, ...). A trace of the original data is
kept with the attribute "origin"
(see below).
`read.nexus' tries to represent correctly trees with a badly
represented root edge (i.e. with an extra pair of parentheses). For
instance, the tree "((A:1,B:1):10);" will be read like "(A:1,B:1):10;"
but a warning message will be issued in the former case as this is
apparently not a valid Newick format. If there are two root edges
(e.g., "(((A:1,B:1):10):10);"), then the tree is not read and an error
message is issued.read.tree
, write.nexus
,
write.tree