[R-lang] colourcoding of leaves in dendrogram

Stefan Th. Gries stgries at gmail.com
Thu Mar 6 12:50:35 PST 2008


Hi

I don't have a solution off the top of my head, but you can look here:
<http://addictedtor.free.fr/graphiques/RGraphGallery.php?graph=79> and
then explore the source code provided.
HTH at least a bit,
STG
-- 
Stefan Th. Gries
-----------------------------------------------
University of California, Santa Barbara
http://www.linguistics.ucsb.edu/faculty/stgries
-----------------------------------------------

On Thu, Mar 6, 2008 at 12:34 PM, Laura Herbst <Laura.Herbst at mpi.nl> wrote:
> Hi R-users
>
>  I have plotted a dendrogram from a diana() object. The leaves are always
>  one out of three categories (e.g. with the labels "1","2","3"). I
>  would like to visualize the distribution of those categories with
>  colours, so that for example all leaves labelled "1" get the color
>  "green", and leaves labelled "2" the color "red" etc.
>  Does anyone have a suggestion how to do this?
>
>  Thank you!
>
>  Best
>  Laura



More information about the R-lang mailing list