I'd like to know HOW I can edit the legend title. It were really hard to control the name displayed in geom_vline, and yet it is wrong since somehow it's change the legend of color scheme.
I'm using ggplot from tidyverse.
Thanks in advance
ggplot(mtcars, aes(x=disp)) + geom_density() +
geom_vline(aes(xintercept=140, color = (green = "p" ) ) ) +
geom_vline(aes(xintercept=300, color = (blue = 's') ) ) +
geom_vline(aes(xintercept=250, color = (red = 'm' ) ) )