[R] clustering, don't understand this error

Christian Hennig chrish at stats.ucl.ac.uk
Thu Apr 16 14:39:27 CEST 2009


Hi there,

I'm travelling right now so I can't really check this but it seems that 
the problem is that cluster.stats needs a partition as input. hclust 
doesn't give you a partition but you can generate one from it using 
cutree.
BTW, rather use "<-" than "=".

Best wishes,
Christian


On Wed, 15 Apr 2009, Ana M Aparicio Carrasco wrote:

> Hello,
> I am using the dunn metric, but something is wrong and I dont understand
> what or what that this error mean. Please can you help me with this?
>
> The instructions are:
>
> #Indice de Dunn
> disbupa=dist(bupa[,1:6])
> a=hclust(disbupa)
> cluster.stats(disbupa,a,bupa[,7])$dunn
>
> And the error is:
>
> Error in max(clustering) : invalid 'type' (list) of argument
>
> thank you so much.
>
> Ana Maria Aparicio.
>
> 	[[alternative HTML version deleted]]
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>

*** --- ***
Christian Hennig
University College London, Department of Statistical Science
Gower St., London WC1E 6BT, phone +44 207 679 1698
chrish at stats.ucl.ac.uk, www.homepages.ucl.ac.uk/~ucakche




More information about the R-help mailing list