如何在R中缩放圆形树状图?

时间:2018-12-17 17:50:18

标签: r plot dendrogram dendextend circlize

我在R中有这个圆形树状图,我想放大它。我该如何进行? 这里是: click here for dendrogram

使用了以下代码:

library(dendextend)
library(circlize)

load(file = "hc1.rda")
#out1 <- cutree(hc1, k = 50)
load(file = "out1.rda")

dend <- as.dendrogram(hc1)
dorder <- order.dendrogram(dend)

colrs = colorRampPalette(c("blue", "red"))(50)
#library(colorBrewer)
# modify the dendrogram to have some colors in the branches and labels
dend1 <- color_branches(dend, col=colrs , 
                        clusters=out1)
#plot(dend1)

# plot the radial plot
par(mar = rep(0,4))
   circlize_dendrogram(dend1, labels_track_height = NA, 
                    dend_track_height = .4, labels = FALSE) 

1 个答案:

答案 0 :(得分:0)

已经晚了,但我尝试了另一种方法来解决此问题。导出图像/ pdf时,我通常将尺寸更改为4的倍数。希望对您有所帮助。