figure - the forecast plot for arima( , , as evident from the plot in figure - the model captures the overall upward trend though it misses out on the sudden jump in values around yet it seems to give pretty nice idea of what can be achieved using this methodology the arima_gridsearch_cv(function produces similar statistics and plots for five different train-test splits we observe that arima( , , provides us decent enough fitalthough we can define additional performance and error criteria to select particular model in this casewe generated forecast for time periods for which we already had data this helps us in visualizing and understanding how the model is performing this is also called as back testing out of sample forecasting is also supported by statsmodels through its forecast(method alsothe plot in figure - showcases values in the transformed scalei log scale inverse transformation can be easily applied to get data back in original form you should also note that commodity prices are impacted by whole lot of other factors like global demandeconomic conditions like recession and so on hencewhat we showcased here was in certain ways naive modeling of complex process we would need more features and attributes to have sophisticated forecasts stock price prediction stocks and financial instrument trading is lucrative proposition stock markets across the world facilitate such trades and thus wealth exchanges hands stock prices move up and down all the time and having ability to predict its movement has immense potential to make one rich stock price prediction has kept people interested from long time there are hypothesis like the efficient market hypothesiswhich says that it is almost impossible to beat the market consistently and there are others which disagree with it there are number of known approaches and new research going on to find the magic formula to make you rich one of the traditional methods is the time series forecastingwhich we saw in the previous section fundamental analysis is another method where numerous performance ratios are analyzed to assess given stock on the emerging frontthere are neural networksgenetic algorithmsand ensembling techniques ##note stock price prediction (along with gold price prediction in the previous sectionis an attempt to explain concepts and techniques to model real-world data and use cases this is by no means and extensive guide to algorithmic trading algorithmic trading is complete field of study on its own and you may explore it further knowledge from this alone would not be sufficient to perform trading of any sort and is beyond both the scope and intent of this book