I want to improve my chart on two different points.
I don't like the numbers on the bottom line so they have to be removed. I want the data label behind the chart and not half in it.
Code for the calculation
select f.ClubName, round(w.Waarde/w.Selectie,0) as Gem_waarde
from fact f
join waarde w
on w.WDID = f.WDID
order by Gem_waarde desc
Chart code
ggplot(df_5, aes(x = fct_reorder(ClubName, Gem_waarde), y = Gem_waarde,fill = as_factor(ClubName))) +
geom_col(position = "dodge2") +
theme(legend.position = "none") +
coord_flip() +
#ylim(20000,5000000)+
labs(x = "Club", y = "waarde per speler") +
geom_text(aes(label = Gem_waarde, Gem_waarde = Gem_waarde + 0.05),
position = position_dodge(0.9),vjust = 0)
Example Data
Club Selectie waarde
1 29 375900000
2 26 211500000
3 28 94780000
4 25 74050000
5 25 44300000
6 27 31050000
7 26 20980000
8 27 19480000
9 25 18980000
10 28 17580000
11 29 17330000
12 26 16330000
13 30 14180000
14 21 14000000
15 28 12330000
16 27 12280000
17 31 11930000
18 28 960000