This question already has an answer here:
I am new to r but am using it for a project in which I wish to represent 3 different y values with same x value on the same scatteplot including linear regression lines for each along with the value. I don't know if what I have done so far is the best but:
leafdata.long<-melt(leafdata, id="Percent.Area.Loss", measure=c("R...mean", "G.mean", "B.mean"))
ggplot(leafdata.long, aes(Percent.Area.Loss, value, color=variable))+
geom_point()+geom_smooth(method=lm, se=FALSE)+opts(title="Compiled Leaf Data")
Here's the plot that it produced: http://imgur.com/eXNFY5d
Any help with changing the x and y labels along with the legend would be appreciated also. I'm very much lost.
The above link seems to do this way nicer. However, since I already had this done by the time I saw the post above I figured I'd post anyways.