spiral_dendrogram | R Documentation |
Draw dendrogram
spiral_dendrogram(dend, gp = gpar(), track_index = current_track_index())
dend |
A |
gp |
Graphical parameters of the dendrogram edges, mainly as a global setting. |
track_index |
Index of the track. |
Graphical parameters for individual edges can be set via the edgePar
attribute on each node in the dendrogram, see stats::dendrogram
for how to set edgePar
.
The dendrogram edges can also be rendered by dendextend::color_branches()
.
Height of the dendrogram.
k = 500
dend = as.dendrogram(hclust(dist(runif(k))))
spiral_initialize(xlim = c(0, k), start = 360, end = 360*3)
spiral_track(height = 0.8, background_gp = gpar(fill = "#EEEEEE", col = NA))
spiral_dendrogram(dend)
require(dendextend)
dend = color_branches(dend, k = 4)
spiral_initialize(xlim = c(0, k), start = 360, end = 360*3)
spiral_track(height = 0.8, background_gp = gpar(fill = "#EEEEEE", col = NA))
spiral_dendrogram(dend)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.