How does the default t-test in R tell you that the relationship between independent and dependent variables is curvilinear? How does the default t-tests in R tell you that the relationship between an independent variable and a dependent variable is curvilinear?
So far I have fitted 2 models using the lm function on one data set. For one of the models I used polynomial regression. I also found the summary for the 2 models. Is the default t-test found in the summary? In which model should I look for the curvilinear relationship; the normal model or the model done with polynomial regression?
 A: The actual t.test function in R does not have a method for lm objects. However, if you look at the coefficient summary using summary on the lm object, the printed output shows the results of a significance test which, like the t-test, takes the regression coefficient, divides by its standard error, compares the Z-statistic to the normal 0,1 distribution, and produces a p-value. Since the regression coefficient is a mean difference, it is often considered a type of t-test. However, the correct terminology for this test is a Wald test.
To test for the presence of non-linearity, you can inspect the statistical significance of the non-linear terms in the polynomial model. For instance, if I adjust for x and x^2 in a model and the x^2 term is significant, this quadratic term is detecting some of the departure from linearity.
Using the lmtest package, you can also apply a likelihood ratio test (LRT) since these are nested models. The command lrtest(model1, model2), will simultaneously test all the non-linear polynomial terms in the second model, and this will be an omnibus for non-linearity.
