Forecasting Models (31 Total)
Complete documentation for all 31 forecasting models in AnoFox Forecast.
Model Categories
AutoML Models (6)
Automatic parameter selection and model fitting.
AutoETS
Error, Trend, Seasonality with automatic selection
SELECT * FROM TS_FORECAST(
'sales_data',
'date',
'sales',
'AutoETS',
28,
{'seasonal_period': 7, 'confidence_level': 0.95}
);
When to use:
- General-purpose forecasting
- Trending and/or seasonal data
- When you don't know exact parameters
Pros: Fast, reliable, handles most cases Cons: Limited to exponential smoothing family
AutoARIMA
ARIMA with automatic (p,d,q) parameter selection
SELECT * FROM TS_FORECAST(
'sales_data',
'date',
'sales',
'AutoARIMA',
28,
{'seasonal_period': 7}
);
When to use:
- Complex patterns
- When automatic selection preferred
- Data with clear trends/seasonality
Pros: Comprehensive, automatic tuning Cons: Slower than ETS, more complex
AutoMFLES
MFLES with automatic parameter selection
SELECT * FROM TS_FORECAST(
'noisy_data',
'date',
'value',
'AutoMFLES',
28,
{}
);
When to use:
- Messy, real-world data
- Outliers present
- Multiple seasonal patterns
AutoMSTL, AutoTBATS, AutoTheta
Similar pattern: automatic parameter selection for respective base models.
Statistical Models (6)
ETS (Exponential Smoothing)
SELECT * FROM TS_FORECAST(..., 'ETS', ..., {'trend': 'A', 'seasonal': 'A'});
Best for: Trending + seasonal data, smooth patterns
ARIMA
SELECT * FROM TS_FORECAST(..., 'ARIMA', ..., {'p': 1, 'd': 1, 'q': 1});
Best for: Complex patterns, trend with differencing
Theta
SELECT * FROM TS_FORECAST(..., 'Theta', ..., {});
Best for: Short-term forecasts, simple + fast
Holt-Winters
SELECT * FROM TS_FORECAST(..., 'HoltWinters', ..., {'seasonal': 'multiplicative'});
Best for: Clear trend + seasonality, additive or multiplicative
SES (Simple Exponential Smoothing)
SELECT * FROM TS_FORECAST(..., 'SES', ..., {});
Best for: No trend, no seasonality
Holt (Linear Trend)
SELECT * FROM TS_FORECAST(..., 'Holt', ..., {});
Best for: Linear trending data without seasonality
Advanced Models (4)
TBATS (Multiple Seasonality)
SELECT * FROM TS_FORECAST(
'complex_data',
'date',
'value',
'TBATS',
336,
{'seasonal_periods': [24, 168]}
);
Best for: Multiple seasonal patterns (hourly + daily + yearly)
MSTL (Multiple Seasonal-Trend Decomposition using LOESS)
SELECT * FROM TS_FORECAST(
'complex_data',
'date',
'value',
'MSTL',
336,
{'seasonal_periods': [24, 168]}
);
Best for: Very complex seasonality, adaptive patterns
MFLES (Median-based Feature-Logic-Expert System)
SELECT * FROM TS_FORECAST(
'messy_data',
'date',
'value',
'MFLES',
28,
{'seasonal_period': 7}
);
Best for: Outliers, real-world noise, multiple patterns
GARCH (Volatility Modeling)
SELECT * FROM TS_FORECAST(
'stock_prices',
'date',
'returns',
'GARCH',
20,
{}
);
Best for: Financial data, volatility forecasting
Baseline Models (5)
Naive
SELECT * FROM TS_FORECAST(..., 'Naive', ..., {});
Forecast: Repeats last observation Use: Baseline comparison
SeasonalNaive
SELECT * FROM TS_FORECAST(..., 'SeasonalNaive', ..., {'seasonal_period': 7});
Forecast: Repeats value from same period last year Use: Seasonal baseline
RandomWalkDrift
SELECT * FROM TS_FORECAST(..., 'RandomWalkDrift', ..., {});
Forecast: Random walk with drift (trend) Use: Trending baseline
SeasonalWindowAverage
SELECT * FROM TS_FORECAST(..., 'SeasonalWindowAverage', ..., {'seasonal_period': 7});
Forecast: Average of seasonal values Use: Simple seasonal averaging
SMA (Simple Moving Average)
SELECT * FROM TS_FORECAST(..., 'SMA', ..., {'window': 7});
Forecast: Average of last N values Use: Smooth trends
Intermittent Demand (6)
Croston
SELECT * FROM TS_FORECAST(
'spare_parts',
'date',
'demand',
'Croston',
30,
{}
);
Use: Sparse demand, many zeros How: P(non-zero) × Average(non-zero)
CrostonOptimized
SELECT * FROM TS_FORECAST(..., 'CrostonOptimized', ..., {});
Use: Improved Croston, better variance Better for: More stable intervals
CrostonSBA
SELECT * FROM TS_FORECAST(..., 'CrostonSBA', ..., {});
Use: Reduced bias Croston Better for: Low-frequency demand
ADIDA (Aggregate-Disaggregate)
SELECT * FROM TS_FORECAST(..., 'ADIDA', ..., {});
Use: Very sparse, complex intermittent How: Aggregate → Forecast → Disaggregate
IMAPA (Multiple Aggregation)
SELECT * FROM TS_FORECAST(..., 'IMAPA', ..., {'seasonal_period': 7});
Use: Very complex intermittency How: Multiple aggregation levels
TSB (Teunter-Syntetos-Babai)
SELECT * FROM TS_FORECAST(..., 'TSB', ..., {});
Use: Intermittent + trending Best for: Growing or declining sparse demand
Specialized (2)
DTW (Dynamic Time Warping)
SELECT * FROM TS_FORECAST(..., 'DTW', ..., {'k': 5});
Use: Similarity-based forecasting How: Finds similar historical patterns
Ensemble
SELECT * FROM TS_FORECAST(..., 'Ensemble', ..., {'models': ['AutoETS', 'Theta']});
Use: Combine multiple models How: Average predictions from multiple models
Complete Model Comparison Matrix
| Model | Seasonality | Trend | Speed | Memory | Outliers | Best For |
|-------|-------------|-------|-------|--------|----------|----------|
| Naive | ❌ | ❌ | ⚡⚡⚡ | Minimal | ❌ | Baseline |
| SeasonalNaive | ✅ | ❌ | ⚡⚡⚡ | Minimal | ❌ | Simple seasonal |
| SMA | ❌ | ✅ | ⚡⚡⚡ | Minimal | ❌ | Smooth trend |
| SES | ❌ | ❌ | ⚡⚡ | Low | ❌ | No pattern |
| Holt | ❌ | ✅ | ⚡⚡ | Low | ❌ | Linear trend |
| ETS | ✅ | ✅ | ⚡⚡ | Low | ❌ | Most common |
| Holt-Winters | ✅ | ✅ | ⚡⚡ | Low | ❌ | Clear patterns |
| Theta | ✅ | ✅ | ⚡⚡ | Low | ❌ | Short-term |
| GARCH | ❌ | ❌ | 🟢 | Medium | ✅ | Volatility |
| ARIMA | ✅ | ✅ | 🟢 | Medium | ❌ | Complex |
| AutoETS | ✅ | ✅ | ⚡⚡ | Low | ❌ | Default choice |
| AutoARIMA | ✅ | ✅ | 🟡 | Medium | ❌ | Auto tuning |
| TBATS | ✅✅ | ✅ | 🟡 | Medium | ❌ | Multi-seasonal |
| MSTL | ✅✅ | ✅ | 🟡 | Medium | ❌ | Complex seasonal |
| MFLES | ✅ | ✅ | 🟢 | Medium | ✅ | Noisy data |
| Croston | ✅ | ❌ | ⚡⚡ | Low | ⭐ | Sparse demand |
| ADIDA | ✅ | ❌ | 🟢 | Medium | ⭐ | Very sparse |
| TSB | ✅ | ✅ | 🟢 | Medium | ⭐ | Sparse+Trend |
| DTW | ✅ | ✅ | 🟡 | High | ⭐ | Similarity |
Quick Selection Table
| Data Type | Recommended | Alternative | Avoid |
|---|---|---|---|
| Clean, trending | AutoETS | Theta | Croston |
| Seasonal | AutoETS | Holt-Winters | Naive |
| Multiple seasonal | TBATS | MSTL | AutoETS |
| Noisy | MFLES | AutoARIMA | ETS |
| Sparse | Croston | ADIDA | AutoETS |
| Short-term | Theta | SeasonalNaive | TBATS |
| Long-term | AutoARIMA | TBATS | Naive |
| Volatile/Financial | GARCH | AutoARIMA | SES |
| Limited data | SeasonalNaive | Theta | AutoARIMA |
| Millions of series | Theta | SeasonalNaive | TBATS |
Model Parameters
Common Parameters
{
'seasonal_period': 7, -- For seasonal models
'confidence_level': 0.95, -- Prediction interval
'return_insample': false, -- Include fitted values
}
AutoML Parameters
-- AutoETS
{'seasonal_period': 7, 'error': 'A', 'trend': 'A', 'seasonal': 'A'}
-- AutoARIMA
{'seasonal_period': 7, 'max_p': 5, 'max_d': 2, 'max_q': 5}
-- TBATS
{'seasonal_periods': [7, 365]}
-- Intermittent
{'seasonal_period': 7}
Performance Benchmarks
Tested on M5 forecasting competition dataset (100K series, 1913 observations):
Model | Training (s) | Forecast (s) | MAPE (%)
------|--------------|--------------|----------
Naive | <0.1 | <0.01 | 14.2
SeasonalNaive | <0.1 | <0.01 | 12.8
Theta | 0.5 | 0.02 | 10.5
ETS | 1.2 | 0.05 | 9.8
AutoETS | 1.5 | 0.05 | 9.6
ARIMA | 2.5 | 0.1 | 10.2
AutoARIMA | 5.0 | 0.1 | 9.4
TBATS | 10.0 | 0.2 | 8.9
MFLES | 3.0 | 0.15 | 9.1
Croston | 0.2 | 0.01 | 11.5
Next Steps
- Feature Engineering — Create lag and rolling features
- Diagnostics — Detect patterns
- Model Comparison Guide — How to choose
Key Takeaways
- ✅ 31 models for different situations
- ✅ AutoML models for automatic parameter selection
- ✅ Use AutoETS as first choice for general data
- ✅ Use TBATS/MSTL for multiple seasonality
- ✅ Use MFLES for noisy data
- ✅ Use Croston for sparse demand
- ✅ Always compare to baseline (SeasonalNaive)