ggplot2绘制面积图
ggplot2绘制面积图的代码格式:
ggplot(sunspotyear, aes(x,y))+ geom_area()
绘制面积图,文件格式如下:
#draw simple...area plot
ggplot(sunspotyear, aes(Year,Sunspots))+
geom_area()
改变填充色
#change fill colour and alpha...ggplot(sunspotyear, aes(Year,Sunspots))+
geom_area(colour="black", fill="blue", alpha=.2)
删除面积图下的黑线...#用优化的参数绘制完美的par图
par(mar=c(0,6,6,6))
pie(data$Value,
labels=paste(data$Group,"(",substring(data$...XXX value of different conditions",
labelrad=1.5, shade=0.5)
pie3D函数并没有设置顺或逆时针的参数,下面是解决方案。