# Testing correlation and the t-statistic used in Simple Linear Regression

Given $H_0$ : $\rho=0$ and $H_A$ : $\rho\neq0$, we use the test statistic $t_{n-2}$ , which is $\frac{r\sqrt{n-2}}{\sqrt{1-r^2}}$. I have to show that $\frac{r\sqrt{n-2}}{\sqrt{1-r^2}}$ equals $\frac{\hat{\beta}}{SE(\hat{\beta})}$ with the hint that $SE(\hat{\beta})=\frac{S_{(Y|X)}}{\sqrt{\sum\limits_{i=1}^{n} (x_i-\bar{x})^2}}$. Any ideas on how to do this?

I do know that $\hat{\beta}=r\frac{S_y}{S_x}$ and that $\sqrt{\sum\limits_{x=1}^{n} (x_i-\bar{x})^2}=S_x$. After doing some algebra, I get $\frac{S_y}{S_{y|x}}=\frac{\sqrt{n-2}}{\sqrt{1-r^2}}$. But I get stuck there.

• Strictly, you don't, since "the Pearson Product-Moment Correlation Coefficient" is $r$, not "$t_{n-2}$". You need to edit your question so that it doesn't call $t_{n-2}$ something it isn't. – Glen_b Jan 27 '15 at 23:17
• Thanks, that's better. It looks like you should also add the self-study tag (and if you haven't seen it before, read through it's tag wiki, though I think your post is pretty close to the guidelines already) – Glen_b Jan 27 '15 at 23:47

I think I got it. $S_{y|x}=\sqrt{\sum(y_i-\hat{y_i})^2}\sqrt{\frac{1}{n-2}}$. Substituting this in we get: $\frac{S_y}{\sqrt{\sum(y_i-\hat{y_i})^2}}\sqrt{n-2}=\frac{\sqrt{n-2}}{\sqrt{1-r^2}}$ The $\sqrt{n-2}$ cancels yielding $\frac{S_y}{\sqrt{\sum(y_i-\hat{y_i})^2}}=\frac{1}{\sqrt{1-r^2}}$ And $S_y$ actually equals $\sqrt{\sum(y_i-\bar{y_i})^2}$ so substituting that in and squaring both sides we get $\frac{\sum(y_i-\bar{y_i})^2}{\sum(y_i-\hat{y_i})^2}=\frac{1}{1-r^2}$ We know that $1-r^2=\frac{SSE}{SST}$ Substituting that in we get $\frac{\sum(y_i-\bar{y_i})^2}{\sum(y_i-\hat{y_i})^2}=\frac{SST}{SSE}$ which is true.