Description Usage Arguments Details Value Author(s) References Examples
Using bottom-up hierarchical clustering, find the set of maximal mutual clusters.
1 | mutualCluster(x, distances, method = "average", plot = FALSE)
|
x |
Data matrix, the rows of which we wish to cluster |
distances |
Distances between objects to be clustered. This may be
a symmetric matrix or a object produced by |
method |
Does not affect mutual clusters returned by mutualCluster. Method used in hclust to join clusters. Must be one of “single”, “complete” or “average”. This option only affects the plotting, since all 3 methods give the same mutual clusters. |
plot |
Flag indicating whether the dendrogram for bottom-up clustering should be displayed. |
A mutual cluster is a group of points such that the largest distance between any pair in the group is smaller than the shortest distance to any point outside the group.
This function relies on the fact that bottom-up clustering with average, single, or complete linkage cannot break a mutual cluster. That is, when agglomerating, these clustering methods will never add points outside the mutual cluster before first joining all points inside the mutual cluster.
The function mutualCluster
is primarily a wrapper that first performs a bottom-up
clustering, and then uses this information to identify the mutual clusters.
The utility functions that make up mutualCluster
are listed under “See
Also:” and can be used separately on a hclust
object for finer control.
A list of mutual clusters. Each component of the list is a vector of observation indices corresponding to one mutual cluster. Only the maximal mutual clusters are returned, so if observations 1 and 2 form a MC, and observations 1, 2, 4 also form a MC, then a vector with elements 1, 2, 4 will be returned.
Hugh Chipman
Chipman, H. and Tibshirani, R. (2006) "Hybrid Hierarchical Clustering with Applications to Microarray Data", Biostatistics, 7, 302-317.
1 2 3 4 5 6 | x <- cbind(c(-1.4806,1.5772,-0.9567,-0.92,-1.9976,-0.2723,-0.3153),
c(-0.6283,-0.1065,0.428,-0.7777,-1.2939,-0.7796,0.012))
par(mfrow=c(1,2))
plot(x,pch=as.character(1:nrow(x)),asp=1) # show data
dist(x) # you can verify that mc's are correct
mutualCluster(x,plot=TRUE) # find MCs and indicate them in dendrogram plot
|
1 2 3 4 5 6
2 3.1020019
3 1.1790848 2.5896601
4 0.5801661 2.5858301 1.2062584
5 0.8428003 3.7668440 2.0120667 1.1948574
6 1.2177358 1.9681753 1.3880566 0.6477028 1.8003235
7 1.3296271 1.8962063 0.7644933 0.9946297 2.1296732 0.7927670
1 : 3 7
2 : 1 4
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.