# How to check my data set is following non-linear to linear regression?

I have two data sets with y and X1,X2,X3,....,X6 all Xi's are independent variables and y is dependent variable.

Instructor said that one data set will follow linear regression and other will follow non- linear regression

I don't have any clue about this, how to check it (linearity/ Non-linearity) with my dataset no

• Can you tag this as a homework question? It might get a better response if it is recognized as such. – Dianne Cook Sep 25 '14 at 15:37

## 1 Answer

You've used the data-visualization tag and that's certainly a place you can start.

You might do a pairs plot (scatterplot matrix) which can sometimes give an indication of nonlinearity. However, sometimes it is hard to see clearly because of the effects of the other variables.

Another alternative is to fit linear models to both and check added-variable plots (or perhaps partial residual plots). Nonlinearity should be better visible there, but it may take adjusting for the nonlinearity in some of the other variables before some of the nonlinearity is clear.

By contrast, the one that's actually linear should not show nonlinearity in added-variable plots.