Follow each step and report (immediate) results at each step.
Correctness + completeness 80% and clarity 20%.
1. Regression on Pearson's father-son data
a) Get the classical Pearson's father-son data by the following R commands
install.packages("UsingR"); library(UsingR); data(father.son);
Or, download the data somewhere from the web (assume it is in a file called father.son.Data which is in the working directory). load it by:
father.son<-read.table("father.son.Data", header=TRUE,sep="");
fheight<-father.son[,1];
sheight<-father.son[,2];
b) Produce a scatter plot of father's height (x axis) Vs son's height (y axis). Example R command:
plot(father.son$fheight, father.son$sheight, xlab="Father's height (in)",
ylab="Son's height (in)", pch=20);
c) Add the regression line on the scatter plot
d) Add the SD line (with blue color, different from the regression line) to the same plot
e) Mark the center of regression
points(mean(father.son$fheight), mean(father.son$sheight));
f) Add horizontal and vertical lines (green color) through the center of regression
g) Report the linear regression output (including R^2 etc)