How can I rearrange my axis, I created a grouped bar chart using ggplot, and my graph is suppose to show the values in increasing orders but the numbers given in the y-axis is all scattered and is not in order. I tried to use various functions but It failed. I also have some inputs that are NA in the Percentage coloumn.
My data sample is:
| Countries | Objectives | Percentage |
|---|---|---|
| Asia | R | 37,5 |
| Asia | C | 18,8 |
| Africa | R | 39,7 |
| Africa | C | 22,4 |
| N.America | R | 65,2 |
| N.America | C | 26,1 |
My list goes on and the code I used to make the graph is
ggplot(mydata, aes(factor(Objectives), Percentage, fill = Countries)) +
geom_bar(stat="identity", position = "dodge") + xlab("")
Thanks for your help in advance