Compute the ultrametric distances for objects representing (total indexed) hierarchies.
an R object representing a (total indexed) hierarchy of objects.
an integer giving the number of objects in the hierarchy.
a character vector giving the names of the objects in the hierarchy.
x is not an ultrametric or a hierarchy with an ultrametric
cophenetic to obtain the ultrametric (also known
as cophenetic) distances from the hierarchy, which in turn by default
calls the S3 generic
as.hclust on the hierarchy.
Support for a class which represents hierarchies can thus be added by
as.hclust methods for this class. In R 2.1.0 or
cophenetic is an S3 generic as well, and one can also
more directly provide methods for this if necessary.
as.cl_ultrametric is a generic function which can be used for
coercing raw (non-classed) ultrametrics, represented as numeric
vectors (of the lower-half entries) or numeric matrices, to
Ultrametric objects are implemented as symmetric proximity objects
with a dissimilarity interpretation so that self-proximities are zero,
and inherit from classes
"cl_proximity". See section Details in the
cl_dissimilarity for implications.
Ultrametric objects can also be coerced to classes
"hclust", and hence in particular use the
plot methods for these classes. By default, plotting an
ultrametric object uses the plot method for dendrograms.
An object of class
"cl_ultrametric" containing the ultrametric
1 2 3 4 5 6 7
Dissimilarities using Ultrametric distances: Alabama Alaska Arizona Arkansas Alaska 48.72515 Arizona 64.99362 64.99362 Arkansas 293.62275 293.62275 293.62275 California 64.99362 64.99362 53.59338 293.62275 Cross-dissimilarities using Ultrametric distances: Colorado Connecticut Alabama 293.62275 293.6228 Alaska 293.62275 293.6228 Arizona 293.62275 293.6228 Arkansas 36.73486 168.6114 California 293.62275 293.6228
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.