I am trying to create some vizualizations with ggplot2 in R but the colors don't match what is in my code and the legend. One line is always pink.
Here is my code:
point = format_format(big.mark = " ", decimal.mark = ",", scientific = FALSE)
p7=ggplot(data) +
geom_line(aes(x=date, y = Neutral, color="deepskyblue", linetype="solid")) +
geom_line(aes(x=date, y = NonNeutral, color="deepskyblue3", linetype="solid"))
p7 + scale_y_continuous(labels = point) + ggtitle("") +
xlab("") + ylab("")
For some reason one of the lines is always pink no matter which color I specify. I need the legend and need colors to match what is said in the legend.
Any insight how to fix this is very welcome.
Thanks for considering this.