Time Series Decomposition Calculator

Upload data, choose period, and reveal hidden structure. Visualize components and check diagnostic metrics instantly. Download reports, share results, and tune decisions faster now.

Calculator Inputs

Paste data as date,value per line. Headers are optional.
Additive: Y = T + S + R. Multiplicative: Y = T × S × R.
Examples: 7 (weekly), 12 (monthly), 24 (hourly daily cycle).
Median helps reduce the influence of spikes.
Centered window size used to smooth the trend.
Median is more robust when seasonal bins have outliers.
Moving windows leave gaps near the start and end.
Interpolation improves stability for sparse series.
Winsorization clamps extreme points without dropping them.
Typical range: 3.0–4.5. Higher means less clamping.
Accepted delimiters: comma, semicolon, or tab. Lines starting with # are ignored.
Reset

Example Data Table

This sample shows a weekly seasonal pattern with a rising trend.

DateValue
2026-01-01120
2026-01-02126
2026-01-03132
2026-01-04128
2026-01-05124
2026-01-06130
2026-01-07138
2026-01-08142

Formula Used

Classical Decomposition
  • Additive: Yt = Tt + St + Rt
  • Multiplicative: Yt = Tt × St × Rt
  • Trend (moving window): Tt = (1/k) Σ Yt+i (k = window size)
  • Seasonal index: average (or median) of detrended values grouped by t mod period
  • Normalization: additive seasonal indices have mean 0; multiplicative indices have mean 1
  • Remainder: additive R = Y − T − S, multiplicative R = Y / (T×S)

Strength metrics use variance ratios in an additive space (log space for multiplicative) to summarize how dominant trend and seasonality are.

How to Use This Calculator

  1. Paste your series as date,value lines, or load the example.
  2. Set the Seasonal Period to match your cycle length.
  3. Choose Additive for constant seasonal swings, or Multiplicative when swings scale with the level.
  4. Select a trend method and window. Larger windows smooth more.
  5. Optionally enable interpolation and outlier winsorization for stability.
  6. Click Decompose Time Series to see components and diagnostics.
  7. Use Download CSV or Download PDF to export results.

FAQs

1) What does time series decomposition do?

It separates observed values into trend, seasonal behavior, and a remainder. This helps you explain changes, detect anomalies, and prepare features for modeling with clearer structure.

2) When should I use additive vs multiplicative?

Use additive when seasonal swings stay about the same size. Use multiplicative when the seasonal swing grows as the series level rises. Auto mode selects a safer model when values are nonpositive.

3) How do I choose the seasonal period?

Pick the length of one repeating cycle. Examples include 7 for daily data with weekly patterns, 12 for monthly data with yearly patterns, and 24 for hourly data with daily patterns.

4) Why can the trend be blank at the edges?

Centered moving windows need future and past points, so the first and last few positions cannot be computed. “Extend trend to edges” fills those ends using the nearest available trend value.

5) What is winsorization with MAD?

It clamps extreme outliers using a robust scale estimate from the median absolute deviation. This reduces distortion without deleting points, improving stability in trend and seasonal estimates.

6) What does “residual lag-1 correlation” mean?

It checks whether the remainder is still autocorrelated at one step. Large positive correlation may suggest missing structure, wrong period, or a trend window that is too small.

7) Why does multiplicative decomposition require positive values?

Multiplicative uses ratios and log-based diagnostics, which break for zero or negative numbers. If your series contains nonpositive values, use additive or transform the data before decomposing.

8) Can I use this output for machine learning features?

Yes. Trend, seasonal, and remainder components often improve forecasting and anomaly detection. Export the CSV and feed the components into your pipeline, then validate performance with backtesting.

Related Calculators

ARIMA Forecast CalculatorGRU Forecast CalculatorMoving Average ForecastSeasonality Detection ToolAuto ARIMA SelectorForecast Accuracy CalculatorMAPE Error CalculatorRMSE Forecast ErrorMAE Error CalculatorCross Validation Forecast

Important Note: All the Calculators listed in this site are for educational purpose only and we do not guarentee the accuracy of results. Please do consult with other sources as well.