20

The data I have are a regression slope value of y~time, a standard error, an n value and a p value, for a particular species in two different areas. I want to check whether the the regression slope for one area is significantly different from the regression slope for the other area - is this possible with such data? Does anyone have any suggestions how I could go about this? I can't get access to the raw data unfortunately...

Sorry that this is such a simple question!

Pere
  • 5,875
  • 1
  • 13
  • 29
Sarah
  • 1,137
  • 4
  • 12
  • 27
  • 2
    This shows how to compare slopes with an interaction F test, direct slope comparison, and Fisher's r-to-z using R code: https://stats.stackexchange.com/a/299651/35304 – Kayle Sawyer Mar 03 '19 at 23:40

3 Answers3

18

The following article might be helpfull to you, as it describes how to evaluate if the effect of a given explanatory factor is invariant over persons, time, or organizations:

Paternoster, R., Brame, R., Mazerolle, P., & Piquero, A. R. (1998). Using the Correct Statistical Test for the Equality of Regression Coefficients. Criminology, 36(4), 859–866.

What they basically say is, that to test the hypothesis that the difference between $b_1$ and $b_2$ (1 and 2 being two samples or times) is equal to zero you can apply the following formula:

$\begin{equation} Z= \frac{b_1-b_2}{\sqrt{{SEb_1}^{2}+{SEb_2}^2}} \end{equation}$

SE being the standard error of the respective 'slopes' in your case.

Marloes
  • 740
  • 6
  • 21
  • 2
    Kwanti, could you please summarize what this article says? – whuber Apr 09 '13 at 18:16
  • 1
    The article is open access here: http://www.udel.edu/soc/faculty/parker/SOCI836_S08_files/Paternosteretal_CRIM98.pdf – Sarah Apr 10 '13 at 15:25
  • 5
    That citation is fine but seems really targeted on a discipline that had lost its way. I think I'd prefer Cohen, J., Cohen, P., West, S. G., & Aiken, L. S. (2003). Applied multiple regression/correlation analysis for the behavioral sciences (3rd ed.). Mahwah, New Jersey: Lawrence Erlbaum Associates, Publishers. page 46-47 which gives you a confidence interval which gives you the standard error calculation from which it is a hop skip and a jump to the Z statistic in the above cited paper. – russellpierce Jul 07 '13 at 01:44
  • 1
    @rpierce: Maybe you can post the details of what your talking about in a separate answer, for those of us without access to that book? – naught101 Feb 27 '15 at 03:44
  • 2
    @naught101 the calculation turns out to be the same. I was only stating an opinion that Cohen et al. is a more authoritative source. – russellpierce Feb 27 '15 at 04:08
  • What are the properties of this test statistic? What is its exact, approximate or asymptotic distribution? – Elias Feb 26 '20 at 20:23
  • @Elias Z is used to denote N(0,1) i.e. a wald test. – thc Oct 17 '20 at 22:00
  • @thc Sure, but it does not necessarily follow a standard normal distribution (need additional assumptions for that). – Elias Oct 18 '20 at 09:08
  • @Elias I believe it's simply a large sample approximation of the central limit theorem. – thc Oct 19 '20 at 05:09
  • @thc Yes, it can be asymptotically standard normal. I'm just saying that I think the answer is not a good answer. There's much more we can say; also, the notation used in the answer is not sufficiently precise. If $b_1$ and $b_2$ are unknown parameters, $Z$ is not even observable; but I guess they are here viewed as averages, but then to test whether they are different or not one only needs to check if they are different or not (no need to conduct a statistical test). – Elias Oct 19 '20 at 08:09
  • @Elias b1 and b2 are estimates of the true slopes, beta1 and beta2. You are not testing for the difference in b1 vs b2, but beta1 vs beta2, hence the need for a statistical test. – thc Oct 19 '20 at 17:34
  • @thc Again, we are talking past each other. Note that the author writes "test the hypothesis that the difference between $b_1$ and $b_2$" but he should write "test the hypothesis that the difference between $\beta_1$ and $\beta_2$", in your notation. Exactly as you say. Hence why I argued that the original post was not well written. – Elias Oct 19 '20 at 18:26
  • Is this approach applicable to multilevel models [like this](https://stackoverflow.com/questions/64585187/getting-an-output-for-difference-of-two-regression-slopes-in-lme4-package) as well? – rnorouzian Oct 29 '20 at 05:18
5

If the slopes come from ordinary least squares regression, it would be good to verify that the year-to-year data which generated these values are indeed independent. Most capture-recapture studies need to account for previous years' volumes using some method of handling the dependence of volume over time.

Using standard errors, you can construct confidence intervals around your slope parameters. A naive test for whether they are different at the correct $\alpha$ level is to inspect whether any of the confidence intervals overlap. (Note the confidence interval from one parameter has to overlap the other actual parameter value, not its confidence interval, in order to fail to reject the null hypothesis that they're different).

AdamO
  • 52,330
  • 5
  • 104
  • 209
  • Thanks AdamO. I have the standard errors already so I could calculate confidence intervals directly from these... Thanks for the tip... – Sarah Apr 08 '13 at 18:21
  • 1
    I missed that. I'll correct my answer to get rid of tedious algebra. – AdamO Apr 08 '13 at 18:22
  • I believe encouraging such a test based on visual inspection is a bad idea. As well, I don't think the stated overlap criteria are very good. Granted you did say 'naive.' The mean and variance are known; how about a *z*-test? – ndoogan Apr 08 '13 at 18:42
  • 1
    That is not a test based on visual inspection. Tests based on the overlap of 95% confidence intervals are equivalent to the Wald test which is consistent and unbiased. It conveniently can also be depicted graphically with a forest plot of 95% confidence intervals. Otherwise, there are no multiple testing issues introduced by this test (a usual consequence of exploratory analyses using excessive plots). – AdamO Apr 08 '13 at 20:22
  • Hello, thank you all for your comments. I have finally managed to get hold of the raw data, so this should simplify things! – Sarah Apr 09 '13 at 16:12
2

The classic (and more statistically powerful) way of testing this is to combine both datasets into a single regression model and then include the area as an interaction term. See, for example, here:

http://www.theanalysisfactor.com/compare-regression-coefficients/

a11msp
  • 743
  • 6
  • 20
  • 6
    This is "more ... powerful" only if more restrictive assumptions apply. In particular, it assumes homoscedasticity of error variances. Often one would not want to assume that (without additional justification) and therefore would use something like the Welch or Satterthwaite t-test. – whuber Mar 30 '16 at 21:46
  • In response to a11msp: What if all your variables are continuous? Can you still use the interaction term to answer this question? – M BG May 13 '20 at 21:53