[R] Generate Dendrogram
farscape2012
farscape2012 at live.com
Mon Apr 30 15:36:09 CEST 2012
Hi
I have a distance matrix which is computed by user defined method. I
would like to plot the dendrogram. I would like to use different color
and want the leaves laying down bottom.
The script like this. I am not familiar with R. I followed the example
shown in
http://stat.ethz.ch/R-manual/R-devel/library/stats/html/dendrogram.html
dist.obj <- as.dist(matrix.distance)
hc.obj <- hclust(dist.obj,method="ave")
dend1 <- as.dendrogram(hc.obj)
plot(hc.obj, xlab='',ylab='',sub='', nodePar=list(pch = c(1,NA),
cex=0.8, lab.cex = 0.8)).
But I got warning and the plot does not look like what I wanted.
Warning messages:
In plot.hclust(hc.obj, xlab = "", ylab = "", sub = "", nodePar =
list(pch = c(1, :
"nodePar" is not a graphical parameter
It also can not recognize
edgePar=
dLeaf=
edge.root
Does someone know what's wrong?
Br,
Luffy
More information about the R-help
mailing list