I have an empirically gathered dataset which relates two variables. Over a small range the relationship appears linear, however over a larger range there is clearly some second order polynomial relationship as can be seen in the image at http://imgur.com/W7f9p.
I'm trying to get a measure of linearity for different ranges considered. E.g. at 20 < x < 60 or 100 < x < 120 it is very linear, but at 20 < x < 180 it is not very linear. I have tried to fit a straight line to the data and calculate the R^2 data (goodness of fit) but this shows that the straight line over the larger range has a better fit than over the smaller range. While this may be true with MS Excel, from the image it is clear that the larger range is less linear...if you hold the side of a piece of paper against the points.
Is there a better way to measure the "linearity" of a dataset?