I have the following data:
mydf = read.table(text=" name ab x 10 15 y 20 25 z 35 45 ", header = T)
I want to create a graph as follows:

I cannot add horizontal lines from dots to a vertical line at x = 50. These lines (blue) were manually drawn in the figure above. I tried the following code, but it does not work:
ggplot(mydf, aes(a, b)) + geom_point()+ geom_vline(xintercept=50)+ geom_line(aes(x=50,y=b, group=name))
source share