Degree of freedom

if I test coefficient GDP, how do I know the degree of freedom = n-1 or n-1-k? if alpha in this case 10% , how do I know it is two tails or one tail test in order to look at the table 5% or 10%. thank you so much for your comments

sales =

10.2 +

(4.6 × CPI) +

(5.2 × IP) +

(11.7 × GDP)

(5.4)

(3.5)

(5.9)

(6.8)

A 90 percent confidence interval for the coefficient on GDP is:

A) –1.5 to 20.0. B) –1.9 to 19.6. C) 0.5 to 22.9.

Your answer: C was correct!

A 90% confidence interval with 176 degrees of freedom is coefficient ± tc(se) = 11.7 ± 1.654 (6.8) or 0.5 to 22.9.

L1 stuff?

Always remember DF = n-k-1

The degrees of freedom in a multiple regression equals n-k-1, where k is the number of variables.

For purposes of testing confidence interval there are some rules, it depends what kind of hypothesis one tests.

The rule of thumb is that

  • if the null hypothsis is that coeff is different from sth, then use two tails value
  • if the null is that coeff is larger/smaller then use one-tailed value

​Note: When you use F-test, always one-tailed value.

I hope it is correct.

but i have one queastion too… is there any differences in number of degrees of freedom if the model is with intercept or without it ?

Like what you said, k = variables. An intercept is not a variable.

hey guys the 1 in n-k-1 is the intercept

k are independent variables,

need to subtract intercept (1) + number of variables (k) from observations (n) to get appropriate degrees of freedom.

this is why for a simple regression with one independent DF = n - 2, (1 for the intercept, 1 for the variable)

Those two should be flipped.

No they should NOT be flipped. Pitmaster1 is correct.

Flip them. This is getting confusing, hold on.

The second one is correct, but the first one is a little confusing.

Example:

H0: x NOT= 10, so Ha: x=10, looks like a 1-tailed test to me.

H0: x =10, Ha: x > 10 or x < 10, that’s two tails for sure.

So, how can H0: x NOT= 10 be 2-tails, and the opposite of that, H0: x = 10 be also 2-tails?

I agree that both bullets under “rule of thumb” is correct. The first bullet is referring to a test like H0: b1 = 0. This would be a two-tailed test, because one way to test this is by obtaining a confidence interval. If the test stat falls out of either the lower bound or the upper bound, you reject the null. Therefore, it is a two-tailed test.

The first bullet says: if the null hypothsis is that coeff is different from sth, then use two tails value

So, it is not referring to a test like H0: b1 = 0, but more like a test like H0: b1 NOT= 0.

Anyway, I think it would still be a 2-tailed test, whether H0: b1 = 0 or H0: b1 NOT= 0.