LU9 Lecture Notes
📚 LU9 Lecture Notes.pdf
Brief overview
This document introduces time series analysis, a method for understanding and predicting data collected over regular intervals. Mastering these concepts is essential for identifying patterns, modeling temporal influences, and forecasting future trends across various fields.
Key points
- Overview of time series data and its four core components: trend, cycles, seasonality, and random effects.
- Understanding the multiplicative time series decomposition model (Y = T × S × I).
- Methods for isolating and estimating trend and seasonal components using moving averages.
- Practical application of the decomposition model for forecasting future time series values (Ŷ = Ť × Ŝ).
- Adjustments for moving averages with odd and even numbers of periods.
1. Introduction to time series analysis
1.1 What is a time series?
- Time series: A collection of numerical data for a random variable observed over time at regular intervals.
- Data is arranged in chronological order.
- A trendline graph visualizes time series data. Time is on the x-axis, and variable values are on the y-axis.
- The main goals of time series analysis are to:
- Identify recurring patterns.
- Model these patterns statistically.
- Forecast future values 2.
1.2 Components of a time series
Time series data are influenced by four underlying forces acting together or separately.
- Trend (T): The long-term upward or downward movement in the data over time.
- Cycles (C): Changes related to economic activity. (Note: Not covered in this course).
- Seasonal variations (S): Fluctuations that repeat at regular intervals, tied to the calendar (e.g., days, weeks, months).
- Random effects (I): Unpredictable variations caused by random influences 3.
Table 1: Time series components
| Component | Description |
|---|---|
| Trend (T) | Long-term movement (increase/decrease) |
| Cycles (C) | Economic activity changes |
| Seasonal (S) | Calendar-related regular fluctuations |
| Irregular (I) | Unpredictable, random influences |
1.3 Identifying components in examples
Analyzing graphs helps identify which components are present in a time series.
-
Quarterly bicycle sales show an approximate constant trend and irregular variations.
. -
Weekly bread sales exhibit an increasing linear trend and irregular variations.
. -
Quarterly hot water bottle sales demonstrate a decreasing linear trend, irregular variations, and seasonal variations.
. -
Quarterly car sales display an increasing linear trend, irregular variations, and seasonal variations.
.
Table 2: Component presence in sales data
| Sales Data | Trend (T) | Seasonal (S) | Irregular (I) |
|---|---|---|---|
| Bicycle sales | Approximate | No | Yes |
| Bread sales | Increasing | No | Yes |
| Hot water bottle sales | Decreasing | Yes | Yes |
| Car sales | Increasing | Yes | Yes |
🔑 Important: Visual inspection of time series graphs is the first step to understanding its underlying structure. 4 5 6 7
2. Time series decomposition model
2.1 Overview of decomposition
The time series decomposition model aims to break down a time series into its constituent components. The classical approach uses a multiplicative model: Y=T×S×I
Where:
- Y is the observed value of the time series.
- T is the trend component, representing the long-term direction.
- S is the seasonal component, reflecting predictable, periodic patterns.
- I is the irregular or residual component, representing random fluctuations.
This model assumes these components are multiplied together to form the observed data. Trend and seasonality are typically modeled, while irregular fluctuations are not.
10.
The goal of decomposition is to isolate and model these components separately. This allows for forecasting future values based on estimated trend and seasonal patterns: Y^=T^×S^
The steps involved in decomposition analysis are:
- Estimate the trend component.
- Estimate the seasonal component.
- Forecast future values.
2.2 Estimating the trend component
The trend component (T^) can be estimated using two primary methods: regression analysis or moving averages.
2.2.1 Trend estimation via regression analysis
Linear regression analysis can be used to find a straight-line trend. The observed time series data (Y) is the dependent variable, and time (X) is the independent variable (X=1,2,3,…,n).
The estimated trend is given by the regression equation: T^=a+bX
Where a is the intercept and b is the slope.
2.2.2 Trend estimation via moving averages
Moving averages smooth out short-term fluctuations in a time series. They are calculated by averaging k successive observations.
The value of k usually matches the number of seasons in the data.
- A moving average value is always centered on a middle time period.
- If k is odd, simple moving averages (MAV) are calculated.
- If k is even, moving averages are calculated first, then successive moving averages are averaged to get a centered moving average (CMAV).
12.
Moving averages calculation
-
Odd k: For a time series of length n and an odd k, calculate the MAV for each period by averaging k consecutive Y values. Example: For k=3, MAVt=(Yt−1+Yt+Yt+1)/3 17.
-
Even k: For a time series of length n and an even k, first calculate MAVs. Then, center successive MAVs by averaging them. Example: For k=4, calculate MAVt.5=(Yt+Yt+1+Yt+2+Yt+3)/4. Then, CMAVt=(MAVt−0.5+MAVt+0.5)/2 18.
📝 Example: To find the MAV for Year 2, Term 1 (t=4) with k=3 (odd), average the Y values for periods 3, 4, and 5: MAV4=(Y3+Y4+Y5)/3 20.
📝 Example: To find the CMAV for Year 1, Quarter 3 (t=3) with k=4 (even), first calculate MAV2.5 and MAV3.5. Then, CMAV3=(MAV2.5+MAV3.5)/2 21.
Moving averages provide a smoothed estimate of the trend, removing cyclical and irregular variations 16.
2.3 Estimating the seasonal component
The seasonal component is estimated using the ratio-to-moving average method. This involves isolating the seasonal and irregular components from the time series.
2.3.1 Calculate seasonal ratios
Seasonal ratios are calculated by dividing each observed time series value (Y) by its corresponding moving average (MAV or CMAV). This ratio, multiplied by 100, represents the seasonal and irregular components.
Seasonal Ratio =MAVY×100
The formula Y=MAV×S×I implies MAVY=S×I.
.
30.
2.3.2 Find median/unadjusted seasonal indices
To represent each season with a single value, the median of the seasonal ratios for each season is calculated. The median is preferred for its resistance to outliers.
- Sort seasonal ratios by season.
- For odd k (number of seasonal ratios per season), the median is the middle value.
- For even k, the median is the average of the two middle values 31.
2.3.3 Calculate adjusted seasonal indices
The sum of the unadjusted seasonal indices should ideally equal k×100 (where k is the number of seasons). If it does not, an adjustment factor is used.
- Sum the median seasonal indices: Calculate the total sum of the unadjusted indices for all seasons 33.
- Calculate the adjustment factor: Adjustment Factor =∑median seasonal indicesk×100 34.
- Adjust the indices: Multiply each median seasonal index by the adjustment factor to obtain the final adjusted seasonal indices. Adjusted Seasonal Index = Median Seasonal Index × Adjustment Factor 35.
These adjusted indices represent the typical seasonal effect for each period 14.
2.4 Forecasting
Forecasting future values involves combining the estimated trend and the estimated seasonal components. The forecasting model is: Y^=T^×S^
Where T^ is the projected trend value for the future period, and S^ is the adjusted seasonal index for that period.
15.
🔑 Important: Decomposition helps in understanding the historical patterns of a time series by separating its trend and seasonal effects, which are then used to predict future values 9.
3. Forecasting future time series values
Forecasting future time series values uses the estimated trend and the adjusted seasonal index. The process involves identifying the future time point and its corresponding season.
3.1 The forecasting formula
The basic formula for forecasting a future time series value is:
Y^=T^×S^
Where:
- Y^ is the forecasted value.
- T^ is the estimated trend value for the future time point.
- S^ is the adjusted seasonal index for the specific season.
This formula combines the long-term direction of the trend with the recurring seasonal patterns to predict future outcomes 37.
3.2 Example forecast calculations
To forecast ice-cream sales for the next four seasons, we use the identified time index (X) and season. The calculations are performed to two decimal places.
📝 Example: For X=8 and a "warmer" season, the forecast is calculated using the trend and the seasonal index for warmer periods.
The following table details the forecast for the next four seasons:
These calculations use the formula Y^=(a+bX)×100adjusted_seasonal_index.
The visual representation of these forecasted values alongside historical data helps in understanding the projected future trends.

🔑 Important: Time index (X) and season are crucial inputs for forecasting future values.
🔑 Important: The forecast combines the trend (T^) and the seasonal index (S^).
🔑 Important: Currency amounts should be written in full letters, such as "dollars" or "euros", not using symbols like "USD" 38.
🔑 Important: Forecasts are estimations and should be interpreted with an understanding of their potential uncertainty.
© 2026 Maeve. All rights reserved. This content is protected by copyright.