You can do an F-test and compare
- the residuals when you use the three different models with different slopes
- the residuals when you use a single model (single same equation, slope 2.0469, for all three groups of data).
This is basically the same answer as Artem, but more explicit. The F-test is the test performed.
This also relates to the Chow test that is mentioned in the question. In Chow's article
To test the equality between sets of coefficients in two linear regressions, we obtain the sum of squares of the residuals assuming the equality, and the sum of squares without assuming the equality. The ratio of the difference between these two sums to the latter sum, adjusted for the corresponding degrees of freedom, will be distributed as the F ratio under the null hypothesis.
an important distinction with Chow's test and a plain ANCOVA for finding difference between two or more models is
This latter sum of squares will be computed only from the first sample of $n$ observations when the second sample is not large enough
This is not your case as you have samples of size 5 to estimate 1 parameter.
The case with more than two regressions is just a generalization, which Chow mentioned himself as well.
While we have dealt with the comparison of coefficients in only two regressions, the proofs of (29) and (50) can obviously be generalized to the case of many regressions.
x = c(1, 2, 3, 4, 5,
2, 4, 6, 8, 10,
1, 3, 5, 7, 9)
y = c(2.1, 4.30, 6.70, 8.20, 10.30,
4.1, 8.25, 12.21, 16.33, 20.47,
2.08, 6.23, 10.11, 14.27, 18.63)
t = as.factor(
c( 1, 1, 1, 1, 1,
2, 2, 2, 2, 2,
3, 3, 3, 3, 3))
# model 1 (different slopes)
mod_complete <- lm(y~0+t+x:t)
# model 2 (same slope)
mod_simple <- lm(y~0+t+x)
# compare whether it improves
# the fit does not improve sufficiently
# RSS (sum of squared residuals) only decrease from from 0.279 to 0.271
# this is considered not siginficant
# (siginficance is tested by F-test
# which includes
# degrees of freedom into the comparison or RSS)
# Thus there is no reason to reject
# the (null / no effect) hypothesis that the lines have the same slope
> anova(mod_simple, mod_complete)
Analysis of Variance Table
Model 1: y ~ 0 + t + x
Model 2: y ~ 0 + t + x:t
Res.Df RSS Df Sum of Sq F Pr(>F)
1 11 0.27933
2 9 0.27100 2 0.0083289 0.1383 0.8727
Model 1: y ~ 0 + t + x Model 2: y ~ 0 + t + x:t Res.Df RSS Df Sum of Sq F Pr(>F) 1 11 0.27933 2 9 0.27100 2 0.0083289 0.1383 0.8727
lm(formula = y ~ 0 + t + x:t)
t1 t2 t3 t1:x t2:x t3:x
0.230 0.026 -0.021 2.030 2.041 2.057
lm(formula = y ~ 0 + t + x)
t1 t2 t3 x
0.179333 -0.009333 0.029556 2.046889