How can I reproduce this graph in ggplot2 (regression lines and data
point superimposed). Thanks, Juliet

filename="http://personality-project.org/r/datasets/heating.txt";
heating=read.table(filename,header=TRUE)
symb=c(19,25,3,23)
colors=c("black","red","green","blue")
plot(degreedays,therms,pch=symb[Location],col=colors[Location],bg=colors[Location],cex=1.0)
by(heating,Location,function(x) abline(lm(therms~degreedays,data=x)))

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to