Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

disdiam

Dissimilarity Diameters of a Partition


Description

Calculates the diameter (maximum within-cluster dissimilarity) of all clusters in a partition, as well as the average diameter across all clusters.

Usage

disdiam(x,dist,digits)
## S3 method for class 'stride'
disdiam(x,dist,digits=3)
## S3 method for class 'disdiam'
print(x, ...)

Arguments

x

a vector of integers or an object of class ‘clustering’, ‘partition’, ‘partana’, or ‘stride’

dist

an object of class ‘dist’ from dist, dsvdis, or vegdist

digits

the number of significant digits reported in the output

...

ancillary arguments to the print function

Details

disdiam is a cluster validation routine, and calculates the diameter (maximum within-cluster dissimilarity) of each cluster, as well as the average diameter of across all clusters of size greater than one.

Value

A list with components:

diameters

a data.frame with clusters as rows, and cluster ID, cluster size, and diameter as cols

mean

the weighted mean diameter of clusters of size greater than one. The mean is weighted for cluster size.

Author(s)

David W. Roberts droberts@montana.edu

Examples

data(shoshveg)
dis.bc <- dsvdis(shoshveg,'bray')
opt.5 <- optpart(5,dis.bc)
disdiam(opt.5,dis.bc)

optpart

Optimal Partitioning of Similarity Relations

v3.0-3
GPL (>= 2)
Authors
David W. Roberts <droberts@montana.edu>
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.