[R] ggplot add a legend?

jcrosbie james at crosb.ie
Tue Dec 18 00:03:29 CET 2012


How to I go about adding a legend  to the following plot?

ggplot() +  geom_line(aes(x=df2010$Price,y=df2010$percentCapacity), colour =
"red") 
+ geom_line(aes(x=df2011$Price,y=df2011$percentCapacity), colour = "green")
+geom_line(aes(x=df2012$Price,y=df2012$percentCapacity), colour = "blue") 
+scale_x_log10()


<http://r.789695.n4.nabble.com/file/n4653389/Rplot01.jpeg> 



--
View this message in context: http://r.789695.n4.nabble.com/ggplot-add-a-legend-tp4653389.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list