Skip to content
SK Subham KumarTSF Hub · time-series forecasting
Learning path

From your first plot to Transformers

A suggested route through the hub. Each step builds on the one before, and every step ends with a model you can run on real data.

Understand the series before modelling it

Plot it. Look for trend, seasonality, outliers and gaps; check stationarity and read the ACF/PACF. Most forecasting mistakes come from skipping this.

Build classical baselines

Fit smoothing and ARIMA-family models first. They’re fast, interpretable and often hard to beat on short or strongly seasonal series. Every fancier model should be compared against them.

Reframe forecasting as supervised learning

Turn the series into a table of lags, rolling statistics and calendar features, then use tree ensembles or regularised regression. Great when you have many external drivers.

Learn sequence models

Recurrent and convolutional networks learn their own features from raw windows. Use them when you have enough history, or many related series to train on together.

Go long-horizon with Transformers

Attention-based models shine on long histories and long forecast horizons. Watch the compute cost, and always benchmark against a simple baseline.

Combine models

Let a linear model capture the structure and a learner model the residuals, stack several forecasters, or fuse multiple views of the same series.

Explore the frontier

Pretrained foundation models forecast new series zero-shot; quantum circuits are an open research question. Benchmark both against everything above.

Model chooser

Which model should I try first?

Rules of thumb, not laws. Start simple, validate honestly, and only add complexity when it beats the baseline.

Your situationStart withThen try
Any problem, firstNaive & seasonal naiveEverything else has to beat these
Short series (a few hundred points) with clear trend or seasonalityETS, Theta, ARIMASARIMAX, Prophet
Several seasonal cycles (hourly data with daily + weekly patterns)TBATSProphet, N-HiTS
Mostly zeros: spare parts, slow-moving itemsCroston / SBATSB (handles obsolescence)
Thousands of series, little history each, or cold startsFoundation models (zero-shot)CatBoost / LightGBM as one global model
Business calendar: several seasonalities, holidays, changepointsProphetNeuralProphet, Prophet-XGBoost
Many external drivers (weather, prices, promotions)SARIMAX, LightGBM on lag featuresTFT
Several series that influence each otherVAR; VECM if they share a long-run trendiTransformer, LSTM
Long history, long horizonDLinear, N-HiTS, PatchTSTInformer, Autoformer, FEDformer
Need prediction intervalsETS / ARIMA (analytic), Gaussian processConformal prediction around any model, DeepAR
Volatile financial returns (forecasting risk, not direction)GARCH, ARIMA-GARCHARIMA-LSTM
Must explain the forecastETS, Elastic netN-BEATS (interpretable), TFT
Noisy sensor data or a series with missing valuesKalman filterMulti-view models

Prefer a guided answer? The AI recommender asks a few questions, and the comparison table lists the trade-offs.

Evaluation

Forecast accuracy metrics, at a glance

\(y_t\) is the actual value, \(\hat{y}_t\) the forecast, \(n\) the number of forecast points.

Scale-dependent

MAE

\[\mathrm{MAE}=\frac{1}{n}\sum_{t=1}^{n}\lvert y_t-\hat{y}_t\rvert\]

Average absolute error in the data’s own units. Robust and easy to explain.

Scale-dependent

RMSE

\[\mathrm{RMSE}=\sqrt{\frac{1}{n}\sum_{t=1}^{n}(y_t-\hat{y}_t)^2}\]

Penalises large misses more heavily. Use it when big errors are costly.

Percentage

MAPE

\[\mathrm{MAPE}=\frac{100}{n}\sum_{t=1}^{n}\left\lvert\frac{y_t-\hat{y}_t}{y_t}\right\rvert\]

Unit-free, so you can compare across series, but it breaks down when actuals are near zero.

Percentage

sMAPE

\[\mathrm{sMAPE}=\frac{100}{n}\sum_{t=1}^{n}\frac{2\lvert y_t-\hat{y}_t\rvert}{\lvert y_t\rvert+\lvert\hat{y}_t\rvert}\]

A symmetric variant that is bounded and less explosive near zero.

Scaled

MASE

\[\mathrm{MASE}=\frac{\mathrm{MAE}}{\frac{1}{T-m}\sum_{t=m+1}^{T}\lvert y_t-y_{t-m}\rvert}\]

Error relative to a seasonal-naïve forecast on the training data (season length \(m\)). Below 1 means you beat the naïve forecast.

Fit

R²

\[R^2=1-\frac{\sum_t (y_t-\hat{y}_t)^2}{\sum_t (y_t-\bar{y})^2}\]

Share of variance explained. Useful, but a high R² on trending data can hide a poor forecaster.

Validate like it’s the future

  • Split by time, never at random. Train on the past, test on what comes after.
  • Backtest with a rolling origin. Re-fit and forecast from several cut-off dates, then average the errors.
  • Fit scalers and imputers on training data only, otherwise the test set leaks into training.
  • Always report a naïve and a seasonal-naïve baseline next to your model.

Common traps

  • Look-ahead features, such as rolling means that include the current target value.
  • Tuning on the test set. Keep a final hold-out you look at only once.
  • One lucky split. A single train/test split can flatter any model.
  • Ignoring the horizon. Accuracy one step ahead says little about accuracy 30 steps ahead.
Resources

Read, practise, build

FAQ

Common questions

What is time series forecasting?

Using historical, time-ordered data to predict future values. It’s used in finance, weather, energy, retail, air quality and many other fields.

Do I need to code to use the hub?

No. The simulator and model pages work without writing code. Every model page also includes Python examples when you’re ready.

Can I use my own data?

Yes. The forecast simulator accepts CSV uploads or data typed in by hand.

How do I choose the right model?

Start with the model chooser above, then use the AI recommender or the comparison table. Always compare against a simple baseline.

How should I read MAE, RMSE, MAPE and R²?

Lower MAE, RMSE and MAPE mean smaller errors; R² closer to 1 means more variance explained. See the metrics section above for when each one misleads.

Which models handle multivariate series?

VAR, SARIMAX (via exogenous inputs), LSTM, TFT and the Transformer family all support multiple inputs. Each model page has details.

What are the limits of AI/ML forecasters?

They often need more data, careful tuning and honest validation, and they can be harder to interpret. Simple models win more often than you might expect.