全部版块 我的主页
论坛 数据科学与人工智能 数据分析与数据科学 R语言论坛
2298 1
2019-03-14
同样的代码
ggplot(titanic[!is.na(titanic$Survived),], aes(x = Survived, fill = Survived)) +
      geom_bar(stat='count') +
      labs(x = 'How many people died and survived on the Titanic?') +
      geom_label(stat='count',aes(label=..count..), size=7) +
      theme_gray(base_size = 15)

别人能做出这样的图 unnamed-chunk-7-1.png
而我的图是这样的
Rplot.png
图例和颜色都不一样,应该如何修改呢?

附件列表
unnamed-chunk-7-1.png

原图尺寸 39.19 KB

unnamed-chunk-7-1.png

二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

全部回复
2019-3-15 09:28:41
fill = factor(Survived)
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

相关推荐
栏目导航
热门文章
推荐文章

说点什么

分享

扫码加好友,拉您进群
各岗位、行业、专业交流群