Time Series
Air Passengers Forecasting with ARIMA
Decompose the classic Air Passengers time series, identify trend and seasonality, fit an ARIMA model, and forecast 12 months ahead.
What
This AI Data Analyst workflow loads the Air Passengers monthly time series from a CSV URL and plots the 1949–1960 passenger counts. It decomposes the series into trend, seasonal, and residual components and checks stationarity using the Augmented Dickey-Fuller test with differencing as needed. It then fits an ARIMA model and generates a 12-month forecast with confidence intervals.
Who
This is for analysts and students learning classical time-series forecasting with decomposition, stationarity checks, and ARIMA modeling. It helps practitioners build a reproducible baseline forecast workflow on a well-known seasonal dataset.
Tools
- pandas
- numpy
- matplotlib
- statsmodels
- scipy
Outcomes
- Time-series line chart showing trend and seasonality (1949–1960)
- Seasonal decomposition plot with trend/seasonal/residual panels
- ADF test output and differencing step to achieve stationarity
- ARIMA model fit summary and diagnostics-ready artifacts
- 12-month forecast plot with confidence intervals
Quality Score
10/10
Last scored: Apr 7, 2026
Task Completion: 2/2
ExcellentAll requested steps are present: data loaded and plotted, decomposition produced, ADF test run with differencing, and a model fit with a 12-month forecast including confidence intervals.
Execution Correctness: 2/2
ExcellentProvided code is coherent and likely runnable end-to-end; outputs show figures and ADF tables were generated, and SARIMAX fit/forecast executed with only non-fatal frequency warnings.
Output Quality: 3/3
ExcellentOutputs match expected outcomes: time-series line chart, 4-panel decomposition, ADF p-values showing non-stationarity then near-stationarity after first differencing, and a forecast plot with confidence intervals.
Reasoning Quality: 2/2
ExcellentInterpretations of trend/seasonality and ADF results are accurate and consistent with the shown statistics; the note about potential seasonal differencing is reasonable given the borderline p-value.
Reliability: 1/1
ExcellentWorkflow is reasonably robust (datetime parsing, period=12, handles NA via dropna); minor fragility remains (frequency inferred rather than explicitly set), but it does not break execution.