Im using the code bellow to plot number of clicks by user. My dataframe is ordered descending:
name value
0 xxxx xxxxxxx 215930
1 yyyyyyyyy 176058
2 zzzzzz 143640
3 qqqqqq 101732
but the bars are randomly plotted.
print ggplot(aes(x="name", y="value"), df) + geom_bar(stat='bar', fill='blue') + theme(axis_text_x = element_text(angle = 90, hjust = 1)) + ylab("Count") + xlab("User")
How can I make the bars (x axis) be ordered by the value on Y?
Thanks