# Comparing linear regressions - what method to use?

#### ulrika

##### New Member
I have a number of measurements of the initial reaction rate of x reactions. Assuming linearity until t = y gives me x linear regressions with different slopes (k). How can I test if there is a significant difference between these k-values?
Hope someone can help!

#### Dason

I don't understand your situation. Can you can try to explain it again in more detail?

#### ulrika

##### New Member
Absolutely!
I have been running a reaction where two reactants form one product. I have been using 3 different reactants in combination with 2 different substrates of the other reactant. And for all of these I have done two replications so in total 12 reactions. For all of these I have measured the consumption of one of the substrates and plotted the consumption vs time in a scatter plot. From this I am assuming that the starting material is consumed linearly for the first 14 samples and therefore I have done a linear regression giving me the equation telling me how fast my starting material is consumed over time. What I first want to do is comparing the slopes of the curves for the replicas of the same reaction to say that all values come from the same population. Afterwards, I would like to compare the slopes of the curves in between different measurements for different starting materials to see of there is a significant difference in consumption rate between substrates.
I wanted to use an ANOVA table but then I'm only comparing the means of all the data points and different sets of data could give the same mean. Or have I gotten it wrong? What I find problematic is that I just want to compare one value to another and not the whole set of data.
Hope this was clearer!

#### GretaGarbo

##### Human
I would like to compare the slopes of the curves
So why don't you compare the slopes? You have the estimated slope and the standards error for that slope. You could do a z-test.

z = (beta1 – beta2)/sqrt(stderr1^2 +stderr2^2)

where beta1 is the estimated regression coefficient in the first regression and stderr1 is the estimated standard error in the first regression, etc. (And it could even be considered as a t-test as the stderr^2 seems to be chi-squared distributed (and divided by its degrees of freedom).)

- - -

On a more principled point, this seems to be a quite common situation in chemistry and biology. They do some kind of regression (linear or non-linear) of their favourite model in a first step. Then they take that regression coefficient and use it as an observation and insert it in data table and run a second model (and do various comparisons).

This seems to me as a multilevel model and I guess that more efficient estimates could be achieved (than using the two-stage method from above).

#### TheEcologist

##### Global Moderator
So why don't you compare the slopes? You have the estimated slope and the standards error for that slope. You could do a z-test.

z = (beta1 – beta2)/sqrt(stderr1^2 +stderr2^2)

where beta1 is the estimated regression coefficient in the first regression and stderr1 is the estimated standard error in the first regression, etc. (And it could even be considered as a t-test as the stderr^2 seems to be chi-squared distributed (and divided by its degrees of freedom).)
The linear model coefficients ( $$\beta_0 , \beta_1$$ ) estimates are theoretically t-distributed (when the errors are normally distributed and their variance is not known).
So for the comparison of slopes, you should actually use the t-distribution. Not that it changes things much, as the t-statistic rapidly converges to the normal at about df = 300 but for small sample-sizes the t should be best.

Last edited:

#### ulrika

##### New Member
Then a t-test is probably best because I have df=26. Thank you for your help!