I am really don't know what I am missing. So, please help me.

I am doing time series analysis. What I want to do is find the predict values.

Here is my data.

848852 705558 829983 761070 826599 795067 840063 764453 885627 797778 781298 915712 810750 701044

I know this is a really small sample to doing time series analysis. But I tried.

I did it unit root test. Through that, I found my data is stationary data.

And I couldn't find seasonal after checking plot.

Actually, I don't know how to find seasonal unit root using r. I just guess checking the graph. So, if you know how to find seasonal unit root, let me know. I would really appreciate it.

Anyway, I got the predict values using Arima model. And the values I get from the Arima model is following.

852427.0 785296.3 815065.3 801864.3 807718.3 805122.3 806273.5 805763.0

805989.4 805889.0 805933.5 805913.8 805922.5 805918.6 805920.4 805919.6

805919.9 805919.8 805919.9 805919.8 805919.8 805919.8 805919.8 805919.8

As you can see, from the 20 value, the values are same. Why is this problem happened???

What should I do to solve this problem??

To sum up, Here is my question.

Q1. What is the minimum sample size to do a time series analysis?

Q2. To find seasonal unit root, what can I do in R program??

Q3. Why I get the same predict values? To solve this problem, what should I do?

I am really appreciated with your help. Thank you.

P.S. Here is my R code.-------------------------------------------------------


848852  705558  829983  761070  826599  795067  840063  764453  885627  797778  781298  915712  810750  701044










for(i in 0:5){

for(j in 0:5){











where[2,]  # the result is (0,1)




You fitted an ARIMA(0,0,1) model, that is, a Moving Average model of order 1:

$$ y_t = c+\theta\epsilon_{t-1}+\epsilon_t, $$

where $\epsilon_t$ is iid white noise.

The expectation point forecast from such a model is calculated by plugging the last residual into $\epsilon_{t-1}$ for the very first prediction, and after that, we plug the expectations into the noise term. Since $E(\epsilon_t)=0$, this means that the forecast will just be $\hat{y}_t=\hat{c}$ after the first forecast data point.

And that is quite fine, since your time series does not exhibit much forecastable pattern at all. It is quite consistent with an MA(1) model. Or alternatively with the flat ARIMA(0,0,0) model (that is, pure white noise) that auto.arima() chooses:

foo <- ts(c(848852,705558,829983,761070,826599,795067,840063,
(model <- auto.arima(foo))

Series: foo 
ARIMA(0,0,0) with non-zero mean 

s.e.   15651.33

sigma^2 estimated as 3.693e+09:  log likelihood=-173.55
AIC=351.11   AICc=352.2   BIC=352.39

Note that a flat mean forecast may definitely outperform more complex ARIMA (or other) models.

Here are a few earlier questions that may be helpful:


I think the problem here is the insufficient data only. When I'm plotting a graph for this data, it can be said, data is stationary. Curve from the data (Please ignore X axis values)

If we also plot Co-relation plot, ACF and PACF plots for this data, Corelation plot for the data ACF plot for the data PACF plot for the data

As it is seen from all the plots that there is no trend information that ARIMA model can learn (In Fig. 2, entire curve is within dotted boundary, In Fig. 3 and 4, the spikes are within shaded region for all the lags values).

So, because there is no trend that model can learn, it is generating some random value closer to training data values, but each prediction will be more or less same because of the data, which is not following any trend.

So, after some iteration, as ARIMA model uses auto-regression(For AR and MA both) on previous values and error terms based on p and q parameter of model, there will be no change in the prediction.

This is also seen from your prediction data, the prediction are converges to one value. Each time model uses some of the previous values to calculate next value, so if all the previous values are same then it will generate same next value.

So, answer of your questions,

Ans.1 : Pick data-set which has some trend in it, means which gives significant spikes in ACF and PACF plots.

Ans.2 : I don't know about unit roots.Sorry.

Ans.3 : This problem can be solved by picking right parameter for ARIMA model (p,d and q values). R has inbuilt function to choose appropriate model. So, it the data follows some trend, model will predict according to that.

Note : This plots are generated using Python.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.