Why is my high degree polynomial regression model suddenly unfit for the data? I'm building a ridge regression model in scikit-learn and trying to find the optimal degree polynomial to use. The data I'm working with is a fairly predictable time series of hourly traffic volumes, and I'm predicting said volumes from the date, hour, and day of the week. R-squared values increase for both my train and test sets as I generate higher degree polynomial features, but suddenly drop from .91 to -1.4 when I go from degree 8 to 9, signifying that the 9th-order model is worse than the 0-order model.  
Any idea why this happens? 
 A: Fitting polynomials to time series data (without prior theory) is in my opinion never a good idea and is definitely anachronistic (i.e. an outdated approach). See Does the p-value in the incremental F-test determine how many trials I expect to get correct? for @w.huber's wise reflection. Perhaps you have latent structure reflecting level shifts/multiple time trends or memory structure using lags of one or more series or even anomalous data points (pulses) or even non-constant error variance. Remedying these issues can often lead to reasonable models as @Sycorax and https://stats.stackexchange.com/users/11887/kjetil-b-halvorsen pointed out.
A: I think this is happening due to overfitting. A large polynomial order model, sometimes tends to perform worse than the original model.
This is due to the fact that the large order model doesn't generalise well on data that it hasn't seen.
An overfit model always reduces the training error. It is natural for the training error to drop as you keep increasing the degree of your model. Infact, at some point, your training error will reach 0.

A: The overfitting could be the reason if you are referring to the drop in accuracy on the testing or validation data. However, even the training accuracy will drop after increasing the polynomial degree beyond a certain threshold. That's why we always need to use the simplest model that fits the data, and avoid "suspicious coincidences" as is referred to in the domain of concept learning. This is called the Bayesian Occam's razor principle, which I have answered similar question about here.
