Compute MPQr distances for a range of values of r
get_mpq_distances.Rd
Compute MPQr distances for a range of values of r
Usage
get_mpq_distances(X, tr, rvec = r_transform(0:100/100))
Arguments
- X
A n x p data matrix.
- tr
A tree (of class
phylo
) with p leaves.- rvec
A vector of values between 0 and 1. For each value in this vector, the function will compute a distance matrix corresponding to the MPQr distance for that value of r. Defaults to a set of values of r that are spaced more closely close to 0 and 1 and more widely around .5 by applying
r_transform
to equally spaced values between 0 and 1.
Value
A list of length 2 whose elements are named distances
and r
. distances
is a list of length length(rvec)
, and each element contains a distance object giving the MPQr distances between the rows of X
for one value of r. The second element of the list (r
) gives the values of r that were used for computing the MPQr distances. These values are given in the same order as the distance objects in the distance
element of the list.