From the given data estimate the slope of the regression line by the least squares method in order to compute coefficient of determination.
The least squares estimate of the slope is
b1=β^1=∑(xi−x)2∑(xi−x)(yi−y)=SxxSxy
where Sxy can be computed using formula
Sxy=∑xiyi−n1(∑xi)(∑yi),
and Sxx can be computed using formula
Sxx=∑xi2−n1(∑xi)2.
The least squares estimate of the intercept is
b0=β^0=n∑yi−β^1∑xi=y−β^1x.