Manually colouring plots with `scale_fill_manual` in ggplot2 not working

前端 未结 1 1049
隐瞒了意图╮
隐瞒了意图╮ 2020-12-19 00:06

I\'m struggling with how to manually change bar colours in ggplot2. Strangely, I can get it to work when using more complicated formats that require a legend by

相关标签:
1条回答
  • 2020-12-19 00:22

    Just in case you are not sure what @baptise means:

    ggplot(ServicesProp, aes(x = Service, y = percent, fill = Service)) + 
      geom_bar(stat = "identity", position = "dodge") + 
      scale_fill_manual(values = c("red", "grey", "seagreen3"))
    

    0 讨论(0)
提交回复
热议问题