Displaying 20 results from an estimated 30000 matches similar to: "hclust, centroid"
2009 Dec 10
1
question about centroid-linkage (cluster analysis)
Dear R community,
I would be greatful if somebody could shed light on the following.
I have created a set of 6 points to check how centroid
agglomeration works in cluster analysis:
> Y <- data.frame(x=c(-1,1,1,-1,10,12),y=c(1,1,-1,-1,0,0))
It is quite intuitive to understand that the last clusters to be joined will be
{1,2,3,4} with {5,6}. Now, the centroid for the first cluster has
2003 Sep 16
0
hclust: median, centroid (PR#4195)
There seems to be a bug in hclust (package mva) for clustering
methods 'median' and 'centroid'.
I have written a clustering program in C and discovered that the
results for 'median' differ from those of hclust in R. I used a
third program, written by someone else in Pascal, and that
program agrees with the output of my program.
I found yet another clustering program that
2012 Jul 04
1
Error in hclust?
Dear R users,
I have noted a difference in the merge distances given by hclust using
centroid method.
For the following data:
x<-c(1009.9,1012.5,1011.1,1011.8,1009.3,1010.6)
and using Euclidean distance, hclust using centroid method gives the
following results:
> x.dist<-dist(x)
> x.aah<-hclust(x.dist,method="centroid")
> x.aah$merge
[,1] [,2]
[1,] -3 -6
2011 Dec 02
0
what is used as height in hclust for ward linkage?
Dear R community,
I am trying to understand how the ward linkage works from a quantitative point of view.
To test it I have devised a simple 3-members set:
G = c(0,2,10)
The distances between all couples are:
d(0,2) = 2
d(0,10) = 10
d(2,10) = 8
The smallest distance corresponds to merging 0 and 2. The corresponding ESS are:
ESS(0,2) = 2*var(c(0,2)) = 4
ESS(0,10)
2012 Nov 18
1
centroid of hclust
Dear UseRs,i want to find centroid of clusters, which i generated by hclust. Is there a way doing that? i took mean to elements in each cluster to get centroid but i am not sure if i am right?
thanks in advanceeliza
[[alternative HTML version deleted]]
2003 Sep 26
1
a. crossing branches with hclust, b. plot.dendrogram
Hello,
a. when I use hclust with the methods media, centroid, and mcquitty,
and plot the results, the dendrograms have lines that are crossing each
other. Is this ok?
b. My next question refers to plot.dendrogram: How can I use parameters
as "hang" or "cex" here? E.g. for
st <- as.dendrogram(subtreeshc[[x]])
I would like to have something like this, where cex and hang
2005 Jul 26
0
Hierarchical clustering with centroid method
Dear everybody!
In the function hclust, at each stage distances between clusters are recomputed by the Lance-Williams dissimilarity update formula according to the
particular clustering method being used.
Using "centroid" method, Lance-Williams recurrence formula works properly only for euclidean distance.
How is it possible to use properly centroid method with manhattan distance ?
2004 Oct 11
1
plot hclust - canberra dist + median linkage
Gives strange results.
I get 'weird' dendrograms with canberra / binary distance metric and
median / centroid cluster methods.
Is this just my data?
Dan
2004 Oct 11
2
hclust title and paste - messed up
I use the following code to scan a (limited) parameter space of clustering
strategies ...
data <- read.table(...
dataTranspose <- t(data)
distMeth <- c("euclidean",
"maximum",
"manhattan",
"canberra",
"binary"
)
clustMeth <- c("ward",
2011 Jul 27
0
Inversions in hierarchical clustering were they shouldn't be
Hi,
I''m using heatmap.2 to cluster my data, using the centroid method for clustering and the maximum method for calculating the distance matrix:
library("gplots")
library("RColorBrewer")
test <- matrix(c(0.96, 0.07, 0.97, 0.98, 0.50, 0.28, 0.29, 0.77,
0.08, 0.96, 0.51, 0.51, 0.14, 0.19, 0.41, 0.51),
ncol=4, byrow=TRUE)
2006 Mar 09
1
HCLUST subroutine question -- FORTRAN DO loops
Shown below is most of the FORTRAN subroutine named HCLUST.
My question concerns the DO loop labeled as '10'. What happened to its
CONTINUE statement? I will assume that after FLAG(I)=.TRUE. is executed that
control returns to DO 10 I=1,N. Am I correct?
Dave
----------------------------
C Initializations
C
DO 10 I=1,N
C We do not initialize MEMBR in order to be able to
2013 Mar 28
2
hierarchical clustering with pearson's coefficient
Hello,
I want to use pearson's correlation as distance between observations and
then use any centroid based linkage distance (ex. Ward's distance)
When linkage distances are formed as the Lance-Williams recursive
formulation, they just require the initial distance between observations.
See here: http://en.wikipedia.org/wiki/Ward%27s_method
It is said that you have to use euclidean
2011 Jul 24
0
setting distance matrix and clustering methods in heatmap.2
heatmap.2 defaults to dist for calculating the distance matrix and hclust for
clustering.
Does anyone now how I can set dist to use the euclidean method and hclust to
use the centroid method?
I provided a compilable sample code bellow.
I tried: distfun = dist(method = "euclidean"),
but that doesn't work. Any ideas?
library("gplots")
library("RColorBrewer")
test
2001 Nov 29
2
memory issue trying to solve too large a problem using hclust
Hi, all.
I'm trying to cluster 12,500 objects using hclust from package mva. The
distance matrix takes up nearly 600 MB. The distance matrix also needs to
be copied when being passed to the fortran routine that actually does the
clustering (it's modified during the clustering), so that's 1200 MB. I'm
actually on a machine with 2.5 GB of memory (and nothing else running), so I
2006 May 08
1
finding centroids of clusters created with hclust
Hello,
Can someone point me to documentation or ideas on how to calculate the
centroids of clusters identified with hclust ?
I would like to be able to chose the number of clusters (in the style of
cutree) and then get the centroids of these clusters.
This seems like a quite obvious task to me, but I haven't been able to
put my hands on a relevant command.
Thank you,
Moritz
2003 Dec 03
1
amap : hclust agglomeration
Hi,
I'm trying to understand the complete linkage method in hclust. Can anyone provide a breakdown of the formula (p9 of the pdf documentation) or tell me what the "sup" operator does/means?
thanks in advance
Tom
[[alternative HTML version deleted]]
2003 Sep 17
1
plot.hclust: dendrogram too large for window (PR#4197)
plot.hclust:
Setting up a window for a dendrogram assumes the first link is
the shortest and the last is the longest. This is not always the
case when the clustering was done with hclust, method="median"
or method="centroid", and the dendrogram sometimes doesn't fit
within the window.
I propose the fix listed below.
src/main/
--- plot.c Wed Sep 17 01:03:39 2003
+++
2009 Sep 21
0
Help needed to clarify hclust and cutree algorithms
Dear R Helpers,
I read carefully the documentation and all postings on the hclust and cutree functions, however some aspects of the tree ordering and cluster assignment performed by these functions remain unclear to me, so I would very much appreciate your help in making sure I get them right.
Here is an example, with values chosen to illustrate the problems.
I have a set of five profiles
2011 Dec 12
1
Is there a way to print branch distances for hclust function?
The R function hclust is used to do cluster analysis, but based on R
help I see no way to print the actual fusion distances (that is, the
vertical distances for each connected branch pairs seen in the cluster
dendrogram).
Any ideas? I'd like to use them test for significant differences from
the mean fusion distance (i.e. The Best Cut Test).
To perform a cluster analysis I'm using:
x
2011 May 11
2
hierarchical clustering within a size limit
Hello List,
I am trying to implement a hierarchical cluster using the hclust method
agglomerative single linkage method with a small wrinkle. I would like to
cluster a set of numbers on a number line only if they are within a distance
of 500. I would then like to print out the members of this list.
So far I can put a vector:
> x<-c(2,10,200,300,600,700)
into a distance matrix:
>