# How is t-statistic calculated for coefficients in linear regression? [duplicate]

After fitting a linear model, in it's summary we can observe coefficients estimates end some statistics about them:

Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept)   1.85600    0.25078   7.401 9.85e-12 ***
Sepal.Width   0.65084    0.06665   9.765  < 2e-16 ***
Petal.Length  0.70913    0.05672  12.502  < 2e-16 ***
Petal.Width  -0.55648    0.12755  -4.363 2.41e-05 ***


I learned that t value is Estimate / Std. Error. However, the formula for one-sample t-value is:

$$t=\frac{\bar{x}-μ}{s_\bar{x}}$$

$$s_\bar{x}$$ is the Std. Error which means that $$\bar{x}-μ$$ must be the Estimate. This is where I got lost. To my understanding the Estimate is the fraction in which given variable contributes to the output. How is it equal to the difference between sample mean and expected mean? What is the expected mean in this case anyway?

• Hi: The null hypothesis tested in regression is that the coefficient is zero so the mean used in the test is zero. – mlofton Nov 12 '20 at 2:23
• "standard error" is the standard deviation of the distribution of some statistic. $s_{\bar{X}}$ is the standard deviation of the distribution of the sample mean, but the sample mean is not the statistic you need the standard error of here. You need the standard error of the regression coefficient. There are some questions on site that relate to standard errors of regression coefficients. – Glen_b Nov 12 '20 at 3:27
• There are two alternate forms for the standard error discussed in the linked duplicates; note that the one involving $R$ doesn't work for the intercept. – Glen_b Nov 12 '20 at 3:48
• @mlofton Thanks a lot. Everything just clicked into place :) – Andrzej Gis Nov 12 '20 at 10:43
• I'm glad it helped. – mlofton Nov 12 '20 at 20:11