pie_addimages将图片添加到饼图中,R语言tastypie包简易饼图
# Wed Sep 08 01:07:42 2021 edit
# 字符编码:UTF-8
# R 版本:R 4.1.1 x64 for window 11
# cgh163email@163.com
# 个人笔记不负责任,拎了个梨🍐🍈
#.rs.restartR()
require(testthat)
rm(list = ls());gc()
img5 <- jpeg::readJPEG(system.file("img", "pie.jpeg", package = "tastypie"))
imgs2 <- list(img5, img5, img5)
df2 <- data.frame(
c("A", "B", "C"),
c(300, 250, 600)
)
mypie2 <- pie_bake(df2, template = "rainbow1")
mypie2
ggplot2::ggsave('pie_addimages将图片添加到饼图中1.jpg',dpi=200)
pie_addimages(
mypie = mypie2,
imglist = imgs2,
perc = "right",
lbl_col = "darkcyan",
border_col = "orangered",
title = "Example"
)
网友评论