Python Forum
ARIMA error with hight MA order - Printable Version

+- Python Forum (https://python-forum.io)
+-- Forum: Python Coding (https://python-forum.io/forum-7.html)
+--- Forum: Data Science (https://python-forum.io/forum-44.html)
+--- Thread: ARIMA error with hight MA order (/thread-16159.html)



ARIMA error with hight MA order - wissam1974 - Feb-16-2019

Hi for all Python expert forum.

i have used the predefined functions in python such as:
plot_acf(col, ax=pyplot.gca(), lags=1500) #to select p value order AR
plot_pacf(col, ax=pyplot.gca(), lags=1500) #to select q value order MA
after analyzing these plots i deducted that
Quote:my model has (0,0,367) as order
.

i am trying to build ARIMA mode in python. here is the code:

def arima_Model_Static_PlotErrorAC_PAC(series, arima_order): 
train, expctd =series , series 
model = ARIMA(series, order=arima_order)
results_MA = model.fit(disp=-1) 
yhatList=results_MA.fittedvalues 
residuals = [expctd[i] - yhatList[i] for i in range(len(expctd))] 
mse = mean_squared_error(expctd, yhatList)
rmse = sqrt(mse)
print(results_MA.summary())
print(rmse)
i called this function as follow:

series=DataSetDiff
arima_order=(0,0,367)
outputResidualError=arima_Model_Static_PlotErrorAC_PAC(series, arima_order)
while i am running my model, i am getting the following error:

Error:
raise ValueError("The computed initial MA coefficients are not " ValueError: The computed initial MA coefficients are not invertible You should induce invertibility, choose a different model order, or you can pass your own start_params
Notes: when i try the
Quote:order(0,0,31)
my model is well running but
Quote:any value greater then 32
i am getting the above mentioned error.

any help will be appreciate.
thank you a lot