[R] Statistically significant in linear and non-linear model
(Ted Harding)
Ted.Harding at manchester.ac.uk
Tue Oct 7 20:16:07 CEST 2008
On 07-Oct-08 17:46:52, Hsiao-nan Cheung wrote:
> Hi,
> I have a question to ask. if in a linear regression model, the
> independent variables are not statistically significant, is it
> necessary to test these variables in a non-linear model?
> Since most of non-linear form of a variable can be represented
> to a linear combination using Taylor's theorem,
That depends on the coefficients in the Taylor's series expansion.
It is quite possible to have the linear coefficient zero, and the
quadratic coefficient non-zero.
> so I wonder whether the non-linear form is also not statistically
> significant in such a situation.
>
> Best Regards
> Hsiao-nan Cheung
> 2008/10/08
Example:
X <- 0.2*((-10):10)
Y <- 0.5*(X^2) + 0.2*rnorm(21)
X2 <- X^2
[A] Linear regression, Y on X:
summary(lm(Y ~ X))$coef
# Estimate Std. Error t value Pr(>|t|)
# (Intercept) 0.72840442 0.1554215 4.6866382 0.0001606966
# X 0.06570652 0.1283351 0.5119919 0.6145564688
So the coefficient of X is not significant.
[B] Quadratic regression, Y on X and X^2:
summary(lm(Y ~ X + X2))$coef
# Estimate Std. Error t value Pr(>|t|)
# (Intercept) 0.003425041 0.07203265 0.04754846 9.625997e-01
# X 0.065706524 0.03957727 1.66020864 1.141924e-01
# X2 0.494304121 0.03666239 13.48259513 7.570563e-11
So the coefficient of X is still not significant (P = 0.14),
but the coefficient of X^2 is *highly* significant!
So it all depends ... of course the original coefficients
(Taylor) could be anything.
Ted.
--------------------------------------------------------------------
E-Mail: (Ted Harding) <Ted.Harding at manchester.ac.uk>
Fax-to-email: +44 (0)870 094 0861
Date: 07-Oct-08 Time: 19:16:04
------------------------------ XFMail ------------------------------
More information about the R-help
mailing list