2
$\begingroup$

Suppose I have the following regression model with two continuous predictors x1 and x2: 𝑦 ~ π‘₯1+π‘₯2+π‘₯2^2+π‘₯1:π‘₯2+π‘₯1:π‘₯2^2. An example regression output is attached below:

x1 <- rnorm(100)
x2 <- rnorm(100)
y <- x1 + x2 + x2**2 + x1*x2 + rnorm(100)

fit <- lm(y ~ x1 + x2 + I(x2^2) + x1:x2 + x1:I(x2^2))

Residuals:
     Min       1Q   Median       3Q      Max 
-2.12678 -0.64983  0.03115  0.59760  2.26080 

Coefficients:
              Estimate Std. Error t value Pr(>|t|)    
(Intercept)   -0.11838    0.12757  -0.928    0.356    
x1             0.95627    0.13901   6.879 6.61e-10 ***
x2             1.04394    0.09099  11.473  < 2e-16 ***
I(x2 * x2)     0.94417    0.06015  15.698  < 2e-16 ***
x1:x2          1.05098    0.12875   8.163 1.45e-12 ***
x1:I(x2 * x2)  0.05926    0.09656   0.614    0.541    
---
Signif. codes:  0 β€˜***’ 0.001 β€˜**’ 0.01 β€˜*’ 0.05 β€˜.’ 0.1 β€˜ ’ 1

Residual standard error: 1.003 on 94 degrees of freedom
Multiple R-squared:  0.8412,    Adjusted R-squared:  0.8328 
F-statistic: 99.59 on 5 and 94 DF,  p-value: < 2.2e-16

Now my question is: given this regression model includes a continuous-by-continuous interaction with a quadratic term (x2). How can I test the significance of the overall interaction effects in this regression model?

  1. Report only the separate p-value of x1:x2 and x1:I(x2*x2) from the regression outputs? If this is the case, how can I interpret the results if the linear interaction term is significant while the quadratic term is not? (I know if without the quadratic term in the regression model, it's very common to report only the p-value of the linear interaction term and that's sufficient for people to judge whether there is a significant interaction. But once the quadratic term is introduced, whether only report the p-value for linear and quadratic interaction term is sufficient to tell people we have a significant interaction?)

  2. Use the likelihood ratio test to compare the full (with all interaction terms) and the nested model (without both linear (x1:x2) and quadratic (x1:I(x2*x2)) interaction term and check if the resulting LRT statistics are significant?)

$\endgroup$

1 Answer 1

1
$\begingroup$

The likelihood ratio test for the two nested models (with all interactions versus without any) would be a good choice in this relatively simple case.

In more complicated situations, you could use a "chunk test," a Wald test on a set of coefficients.

$\endgroup$

Your Answer

By clicking β€œPost Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.