Hello Daniel,
Try this small manipulation ('tr' is your tree and 'node' stores the label of
the node):
i - which(tr$node.label == node)
j - which(tr$edge[, 2] == i + Ntip(tr))
tr$edge.length[j] - 0
Then di2multi(tr) will do the job. (Hopefully, there's originally no
zero-length branch in
Hi Jonathan,
you probably mixed up positive matrices and positive definite matrices.
To have only positive eigen values a matrix must be positive definite.
Covariance matrices are for example are always positive semi-definite,
even though they can contain negative entries.
D is symmetric
My suggestion below should work with trees initially with zero-length branch if
using a negative value instead of 0, e.g.:
tr$edge.length[j] - -1
Then di2multi(tr, tol = -0.5)
Emmanuel
-Original Message-
From: Emmanuel Paradis emmanuel.para...@ird.fr
Sender: