我似乎收到了LinAlgError:LU分解错误。当我运行VARMA模型时。有人知道这个错误是什么意思吗?另外我该如何解决?
energy['Date']=pd.to_datetime(energy['Date'])
energy=energy.set_index('Date')
energy_transform=energy.copy()
energy_transform['Midpoint']=np.log(energy_transformed.iloc[:]).diff(1)
cdd_hdd=cdd_hdd.dropna()
cdd_hdd=cdd_hdd.replace(0,np.nan)
cdd_hdd.columns=(['Date', 'Buffalo NY - KBUF CDD','Baltimore MD - KBWI CDD','Baltimore MD - KBWI HDD', 'Washington DC - KDCA HDD', 'Norfolk VA - KORF CDD', 'Norfolk VA - KORF HDD','Richmond VA - KRIC CDD', 'Richmond VA - KRIC HDD', 'Syracuse NY - KSYR CDD'])
cdd_hdd['Date']=pd.to_datetime(cdd_hdd['Date'])
cdd_hdd=cdd_hdd.set_index('Date')
cdd_hdd_transformed=cdd_hdd.copy()
nny_df=pd.merge(energy_transform, cdd_hdd_transformed, how='outer', left_index=True, right_index=True)
nny_train=nny_df.iloc[:,:]
model = sm.tsa.VARMAX(nny_df, order=(1,1), enforce_stationarity=False, trend='c')
model_result=model.fit(maxiter=1000, disp=False)
print(model_result.summary())