A Time Series Analysis and Forecasting of Opening Stock Price of McDonald’s Crop

Abstract McDonald’s Corp. is globally famous and is abounded in recent years. It is one of the major chain restaurants that offers a fast food. Basic foods that are served at McDonald’s are different types and sizes of burgers, fries, some breakfast, sweets, ice cream and kid’s meals. McDonald’s products have increased loyalty from customers, which has led to the rise of an uneven stock price. So the data is not stationary and makes the role of the analyst’s ability to forecast the future condition of the organization important. The aim of this paper is to analyze and forecast the opening stock price of McDonald’s Corp. over a period time.


Data Description
The Time Series Analysis of the opening price of McDonald's Corp. from January 2006 to December 2014 is complete. Real time data of the opening stock price of McDonald's Corp. is collected from yahoo finance. Source Link:(http://finance.yahoo.com/q/hp?s=AAPL&a=11&b=12&c=1980&d=3&e=1&f=2016&g=d& z=66&y=0).   The first procedure is to check for stationarity in all-time series analysis. The obvious increasing trend showed in the time series plot indicates a non-stationarity. The ADF Test results a P-value of 0.4892, which also indicates as the original data is not stationary with a 5% level significance.

Series McDonald's Corp.Open Price
The slow decline in the Autocorrelation Function (ACF) plot indicates that the observations are correlated or not independent, and also the immediate cut in the Partial Autocorrelation Function (PACF) plot also confirms that. Thus, the original data is neither stationary nor does it indicate the existence of a trend in the data set.
Obviously the trend of McDonald's Corp. stock price indicates an upward parabola. This shows that a lag 1 differencing needs to be taken in order to stabilize and make the trend linear. First, the lag 1 difference of the data is taken. The time series plot of lag 1 difference shows that it seems to be mean stationary, but the variance is non-stationary. The variance increases as time goes on. Therefore, logarithmic transformation needs to be taken into consideration. Take the log transformation on the original data, the time series plot of the transformed data looks better than that of the original data since the increase or drop isn't as severe as was before, which indicates log transformation performs well in eliminating the variance non-stationary. Take the log transformation on the lag 1 difference of original data. The time series looks pretty good, both mean and variance seems to be stationary. The ADF Test results a P-value of 0.01, which indicates the lag 1 difference logarithmic transformed data is stationary with 5% level of significance. ACF and PACF plot confirms that the transformed data is stationary both in mean and variance. Also, from the ACF and PACF plot it is clear that the transformed data is White Noise.  As seen in the time series diagram output, the model is valid or acceptable for the following reasons. The ACF of the residual confirms that the residuals are White Noise. In addition, all the P-values of the Ljung-box statistics are way above the boundary, which confirms the non-independence of the residuals.

Model Equation
The last equation is the final model.  The sequence plot of the standardized residuals looks random, which shows the independent assumption holds. In the normal probability plot, there is some minor curvature to the plot with possible outliers, but the Shapiro-Wilk Test indicates that normality of the error terms in the ARIMA (0,1,0) model cannot be rejected. In summary, the time series seems to be well-represented by the ARIMA (0,1,0) model.

Forecasting and Summary
We fitted an ARIMA (0,1,0) model on the log transformed data, which indicates the algorithm of the original data is an AR (1) model. The forecast values of the next twelve months are showed below, with a 95% confidence interval:  There is no big gap between the actual values and forecasts, which indicates that the model is good. In addition, the 95% confidence interval increases as time goes on, so that a more accurate prediction for recent observations can be given, while less accurate predictions for further observations are given.
In this model, the data series are monthly stock prices, in which one month is not considered short term to stock market. Therefore, it's reasonable that the model is some kind of White Noise since monthly data can be regarded as long term data series. That is to say, in a long term, stock price is hard to predict or even unpredictable just based on the past observations.
Many other forms of research also present the potential of ARIMA models in predicting stock prices in a short term basis, which could benefit the investment decision making. In a short term, as a backward looking statistical method, time series model which was built to outperform the way of randomly guessing the fluctuation of future stock price. However, since the model doesn't consider the events and information that would influence the stock price, one can hardly say in a long term that stock prices can be forecasted accurately.