这是我的代码:
a <- ggplot(euro.groups, aes(x = Group, y = average_emp)) +
geom_bar(aes(fill = params$industry),
stat = "identity",
position = "dodge") +
ggtitle("% of Employment by Group") +
xlab("Group") +
ylab("% Employed in Industry") +
scale_fill_manual("legend", values = c("EU" = "blue", "Eastern" = "red",
"EFTA" = "green", "Other" = "black")) +
theme_grey()
在该图上将有四个小节。我可以通过“组”为它们分配不同的颜色吗?谢谢!