Univariate Linear Regression model assumes that the conditional expectation is a linear function of a single variable 𝑥:

  • 𝑦̂ = 𝑓(𝑥) = 𝐄[𝑌|𝑋=𝑥] = 𝜃0+ 𝜃1𝑥

where:

  • 𝜃0 = 𝑓(0) # 𝑦 intercept
  • 𝜃1 = 𝛿𝑦/𝛿𝑥 # slope along 𝑥 axis

Estimating 𝜃0 and 𝜃1(Ordinary Least Squares Method)

(Regression Slope 𝜃1) in relation to (Correlation Coefficient 𝑟𝑥𝑦)

(Regression Slope 𝜃1) in relation to (Covariance 𝑠𝑥𝑦2)

Analysis of Variance (ANOVA) - Prediction - Further Inference

sections:

  • evaluate the goodness of fit of the chosen regression model to the observed data
  • estimate the variance of response variable 𝑌𝑖given 𝑋𝑖: 𝑉𝑎𝑟(𝑌𝑖|𝑋𝑖) = 𝜎2with 𝜎̂2
  • then use 𝜎̂2 to test the significance of regression parameters: 𝜃0and 𝜃1
  • construct confidence intervals and prediction intervals
Total Sum of Squares = Regression Sum of Squares + Error Sum of Squares
R-Square (Coefficient of Determination)
Standard Regression Assumptions
Degrees of Freedom
Estimating Population-Error/Regression Variance 𝜎2= 𝑉𝑎𝑟(𝑌|𝑋) With 𝜎̂2 Mean Square Error (MSE)
ANOVA Table Summary
  • 𝑆𝑆𝑇𝑂𝑇 = (𝑛 - 1)𝑉𝑎𝑟(𝑦)
  • 𝑆𝑆𝑅𝐸𝐺 = 𝑟2(𝑛 - 1)𝑉𝑎𝑟(𝑦)
  • 𝑆𝑆𝐸𝑅𝑅 = (1 - 𝑟2)(𝑛 - 1)𝑉𝑎𝑟(𝑦)

This table is a modification of One-Way ANOVA and can be used for both univariate linear regression and multivariate linear regression

Source

Sum of Squares

Degrees of Freedom

Mean Squares

𝐹 Statistic (ALL)

Total

Sum of Squares Total (TSS)
Sum of Squares Restricted
Sum of Squares Around Mean

  • 𝑆𝑆𝑇𝑂𝑇 = 𝛴1≤𝑖≤𝑛[𝑦𝑖 - 𝑦̅]2
  • 𝑆𝑆𝑇𝑂𝑇= 𝑆𝑆𝑅𝐸𝐺 + 𝑆𝑆𝐸𝑅𝑅

𝑑𝑓𝑇𝑂𝑇 = 𝑛 - 1

Error

Sum of Squares Error (ESS)
Sum of Squares Residual (RSS)
Sum of Squares UnRestricted
Sum of Squares Around Model

  • 𝑆𝑆𝐸𝑅𝑅 = 𝛴1≤𝑖≤𝑛[𝑦𝑖 - 𝑦̂𝑖]2 = 𝛴1≤𝑖≤𝑛[𝑒𝑖]2

𝑑𝑓𝐸𝑅𝑅= 𝑛 - # of model params including 𝜃0
𝑑𝑓𝐸𝑅𝑅= 𝑛 - (𝑘 + 1)
𝑑𝑓𝐸𝑅𝑅= 𝑛 - 𝑘 - 1

𝑀𝑆𝐸𝑅𝑅 = 𝑆𝑆𝐸𝑅𝑅 / 𝑑𝑓𝐸𝑅𝑅

Mean Square Error (MSE)
Regression Variance

𝑀𝑆𝑅𝐸𝐺/ 𝑀𝑆𝐸𝑅𝑅

this 𝐹 formula is used to test significance of the ENTIRE regression model

for other 𝐹 formulas used to test PARTIAL significance of regression model consult table below

Model

Sum of Squares Regression (RSS)
Sum of Squares Explained (ESS)

  • 𝑆𝑆𝑅𝐸𝐺 = 𝑆𝑆𝑇𝑂𝑇 - 𝑆𝑆𝐸𝑅𝑅 
  • 𝑆𝑆𝑅𝐸𝐺 = 𝛴1≤𝑖≤𝑛[𝑦̂𝑖 - 𝑦̅]2

𝑑𝑓𝑅𝐸𝐺 = 𝑑𝑓𝑇𝑂𝑇 - 𝑑𝑓𝐸𝑅𝑅
𝑑𝑓𝑅𝐸𝐺 = (𝑛 - 1) - (𝑛 - # of model params)
𝑑𝑓𝑅𝐸𝐺 = (# of model params) - 1
𝑑𝑓𝑅𝐸𝐺 = 𝑘 = number of predictor variables 𝜃𝑖‘s excluding 𝜃0

𝑀𝑆𝑅𝐸𝐺 = 𝑆𝑆𝑅𝐸𝐺 / 𝑑𝑓𝑅𝐸𝐺

𝐹 statistic for testing the null hypothesis that ALL variables are insignificant (e.g. 𝐻0: 𝜃1= … 𝜃𝑘 = 0)

𝐹 statistic for testing the null hypothesis that SOME variables are insignificant (e.g. 𝐻0: 𝜃𝑖= 0, ∀𝜃𝑖∊𝑆 where 𝑆⊆{𝜃1, … 𝜃𝑘})

unrestricted model

  • 𝑦̂𝑢𝑛𝑟𝑒𝑠𝑡𝑟𝑖𝑐𝑡𝑒𝑑 = 𝜃0+ 𝜃1𝑥1 + … + 𝜃𝑘𝑥𝑘

restricted model

  • 𝑦̂𝑟𝑒𝑠𝑡𝑟𝑖𝑐𝑡𝑒𝑑 = 𝜃0+ 0·𝑥1 + … + 0·𝑥𝑘= 𝜃0 = 𝑦̅

𝐹 sum of squares form

  • 𝐹 = 𝑀𝑆𝑅𝐸𝐺/ 𝑀𝑆𝐸𝑅𝑅
  • 𝐹 = [(𝑆𝑆𝑇𝑂𝑇𝑆𝑆𝐸𝑅𝑅)/((𝑛 - 1)-(𝑛 - 𝑘 - 1))] / [(𝑆𝑆𝐸𝑅𝑅)/(𝑛 - 𝑘 - 1)]
  • 𝐹 = [(𝑆𝑆𝑇𝑂𝑇𝑆𝑆𝐸𝑅𝑅)/(𝑘)] / [(𝑆𝑆𝐸𝑅𝑅)/(𝑛 - 𝑘 - 1)]
  • 𝐹 = [(𝑆𝑆𝑟𝑒𝑠𝑡𝑟𝑖𝑐𝑡𝑒𝑑- 𝑆𝑆𝑢𝑛𝑟𝑒𝑠𝑡𝑟𝑖𝑐𝑡𝑒𝑑)/(𝑘)] / [(𝑆𝑆𝑢𝑛𝑟𝑒𝑠𝑡𝑟𝑖𝑐𝑡𝑒𝑑)/(𝑛 - 𝑘 - 1)]

𝐹 𝑅2 form

  • 𝐹 = [𝑅2𝑢𝑛𝑟𝑒𝑠𝑡𝑟𝑖𝑐𝑡𝑒𝑑/𝑘] / [(1 - 𝑅2𝑢𝑛𝑟𝑒𝑠𝑡𝑟𝑖𝑐𝑡𝑒𝑑)/(𝑛 - 𝑘 - 1)]

unrestricted model

  • 𝑦̂𝑢𝑛𝑟𝑒𝑠𝑡𝑟𝑖𝑐𝑡𝑒𝑑 = 𝜃0+ 𝜃1𝑥1 + … + 𝜃𝑘𝑥𝑘

restricted model

  • 𝑦̂𝑟𝑒𝑠𝑡𝑟𝑖𝑐𝑡𝑒𝑑 = 𝜃0 + (linear combination of 0·𝑥𝑖 for 𝜃𝑖∊𝑆) + (linear combination of 𝜃𝑗𝑥𝑗 for 𝜃𝑗∉𝑆)
  • 𝑦̂𝑟𝑒𝑠𝑡𝑟𝑖𝑐𝑡𝑒𝑑 = 𝜃0 + (linear combination of 𝜃𝑗𝑥𝑗 for 𝜃𝑗∉𝑆)

𝐹 sum of squares form

  • 𝐹 = [(𝑆𝑆𝑟𝑒𝑠𝑡𝑟𝑖𝑐𝑡𝑒𝑑 - 𝑆𝑆𝑢𝑛𝑟𝑒𝑠𝑡𝑟𝑖𝑐𝑡𝑒𝑑)/((𝑛 - (𝑘-|𝑆|) - 1)-(𝑛 - 𝑘 - 1))] / [(𝑆𝑆𝑢𝑛𝑟𝑒𝑠𝑡𝑟𝑖𝑐𝑡𝑒𝑑)/(𝑛 - 𝑘 - 1)]
  • 𝐹 = [(𝑆𝑆𝑟𝑒𝑠𝑡𝑟𝑖𝑐𝑡𝑒𝑑 - 𝑆𝑆𝑢𝑛𝑟𝑒𝑠𝑡𝑟𝑖𝑐𝑡𝑒𝑑)/(|𝑆|)] / [(𝑆𝑆𝑢𝑛𝑟𝑒𝑠𝑡𝑟𝑖𝑐𝑡𝑒𝑑)/(𝑛 - 𝑘 - 1)]

𝐹 𝑅2 form

  • 𝐹 = [(𝑅2𝑢𝑛𝑟𝑒𝑠𝑡𝑟𝑖𝑐𝑡𝑒𝑑- 𝑅2𝑟𝑒𝑠𝑡𝑟𝑖𝑐𝑡𝑒𝑑)/(|𝑆|)] / [(1 - 𝑅2𝑢𝑛𝑟𝑒𝑠𝑡𝑟𝑖𝑐𝑡𝑒𝑑)/(𝑛 - 𝑘 - 1)]

𝐹 has f-distribution with parameters (𝑘, (𝑛 - 𝑘 - 1))

𝐹 has f-distribution with parameters (|𝑆|, (𝑛 - 𝑘 - 1))

Link to original

T-Test on Regression Slope (𝜃1)
ANOVA F-Test on Model Significance
F-Test vs T-Test
Prediction (Confidence Interval & Prediction Interval)