时间序列 Python:"Key Error" `start` 参数无法匹配

Time Series Python : "Key Error" `start` argument could not be matched

I have trained data set with ARIMA model ,while predicting I am struggling with below error.

train and valid 表示训练和验证数据集..

Code:
model = ARIMA(train, order=(2, 0, 0))
model_fit = model.fit(disp=1)

start_index = valid.index.min()
end_index = valid.index.max()

#Predictions
predictions = model_fit.predict(start=start_index, end=end_index)

当列车数据中的日期时间缺少值时会出现此错误。

您可能会在数据集中找到一些 NA 值。 填充这些数据点可能会消除错误。