Description Usage Arguments Value Author(s) References See Also Examples
Plot clusters with colors obtained from hard density. Plot one dimensional data with density plot. Plot two dimensional data with scatter plot. Pairwise scatter plot will be provided for data with more than two dimensions.
1 |
hmacobj |
The output of HMAC analysis. An object of class 'hmac'. |
level |
The specified level of HMAC output |
n.cluster |
The specified number of clusters. If neither |
plot |
Get the plot of the clusters with different colors. Default value is TRUE, draws a plot on the current graphics device; plot=FALSE indicates do not get the plot and returns the membership of data. |
colors |
Colors used to represent different clusters. |
... |
Further graphical parameters |
Returns the membership of each observation of the specified level if plot=FALSE
Surajit Ray and Yansong Cheng
Li. J, Ray. S, Lindsay. B. G, "A nonparametric statistical approach to clustering via mode identification," Journal of Machine Learning Research , 8(8):1687-1723, 2007.
Lindsay, B.G., Markatou M., Ray, S., Yang, K., Chen, S.C. "Quadratic distances on probabilities: the foundations," The Annals of Statistics Vol. 36, No. 2, page 983–1006, 2008.
phmac
for front end of using modal clustering and also for parallel implementation of modal clustering
soft.hmac
for soft clustering at specified levels.
See plot.hmac
.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | data(disc2d.hmac)
#disc2d.hmac is the output of phmac(disc2d,npart=1)
hard.hmac(disc2d.hmac,level=3)
#returns the membership of each observation
disc2d.2clus=hard.hmac(hmacobj=disc2d.hmac,n.cluster=2,plot=FALSE)
table(disc2d.2clus)
#hard.hmac(disc2d.hmac)
iris.hmac=phmac(iris[,-5])
# For more than two dimensions it produces the pairs plot
hard.hmac(iris.hmac,n.cluster=2)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.