Confidence interval for slope of regression

confidence intervalregressionstatistical-inferencestatistics

I want to run a test for the slope of regression with
$H_0: \text{slope}=0, H_a: \text{slope}>0$

Slope estimate: $4.034$, std. error $=0.250$, sample size $=144$.

However, if I find the one sided $95\%$ confidence interval I get $(-\infty, 4.034 + ME)$. The interval always contains $0$ so it means I can't reject the null hypothesis at any point.

So if the slope estimate $x>0$, the upper bound will always be positive. Does it mean I can't reject the null hypothesis at any point for a one sided test?
I know I am making an logical error at some point but I simply cant figure out where. Any advice would be really appreciated thanks!

Best Answer

In a simple linear regression model $y_i=\alpha+\beta x_i+\varepsilon_i\,,\,i=1,2\ldots,n$ where the errors $\varepsilon_i$ are i.i.d $N(0,\sigma^2)$ with $\sigma$ unknown, a usual test statistic for testing $H_0:\beta=\beta_0$ against $H_a:\beta>\beta_0$ for some given $\beta_0$ is

$$T=\frac{\hat\beta-\beta_0}{\operatorname{s.e.}(\hat\beta)}\stackrel{H_0}\sim t_{n-2}\,,$$

where $\hat\beta$ is the least square estimator of the slope $\beta$ and $\operatorname{s.e.}(\hat\beta)$ is the estimated standard error of $\hat\beta$.

We reject $H_0$ at $5\%$ level of significance if $\text{observed } T>t_{0.05,n-2}$ where $t_{0.05,n-2}$ is the upper $5\%$ point of a $t$ distribution with $n-2$ degrees of freedom. When $n$ is large as in your case, the $t$ distribution is closely approximated by a standard normal distribution.

You have $\beta_0=0$, so the observed value of $T$ is about $16.136$ which exceeds the tabulated value $t_{0.05,142}\approx 1.645$. This suggests you should reject $H_0$ at $5\%$ level of significance.

To find a confidence interval from the above test, we consider the acceptance region associated with $$\frac{\hat\beta-\beta}{\operatorname{s.e.}(\hat\beta)}<t_{0.05,142}$$

That is, $$\beta>\hat\beta-\operatorname{s.e.}(\hat\beta)t_{0.05,142}$$

So a $95\%$ confidence interval for $\beta$ based on the data is approximately $(3.62275,\infty)$. Clearly you will always reject $H_0$ based on this interval.

Related Question