5
Bên trái là cách biểu đồ bánh rán của tôi hiện trông giống như và bên phải làm thế nào nó sẽ giống như thế:Làm thế nào để phát nổ bánh rán biểu đồ lát bằng R (ggplot2)
Có cách nào để phát nổ biểu đồ bánh rán sử dụng R?
Đây là mã của tôi:
ggplot(dat, aes(fill = goalGroups, ymax = ymax, ymin = ymin, xmax = 4.8, xmin = 3)) +
geom_rect(color = "white") +
coord_polar(theta="y", direction = -1) +
xlim(c(0, 8)) +
theme_bw() +
theme(panel.grid=element_blank()) +
theme(axis.text=element_blank()) +
theme(axis.ticks=element_blank()) +
theme(axis.title.x = element_blank()) +
theme(axis.title.y = element_blank()) +
theme(panel.border = element_blank())
Tôi rất biết ơn sự giúp đỡ nào!