尝试使用ggplot2创建饼图,但似乎无法在线使用其他参考.我创建的图表缺少大部分填充.
ggplot(sae,aes(x=1,fill=factor(State), width=1))+ geom_bar()+ ggtitle("House by State")+ coord_polar(theta='y')
此代码给出:
我如何填写中心?
任何其他改进赞赏.
graphics r ggplot2 pie-chart
ggplot2 ×1
graphics ×1
pie-chart ×1
r ×1