0% found this document useful (0 votes)
3 views36 pages

Topic 7.S2

This document covers time series analysis and forecasting methods in banking and finance, focusing on quantitative techniques. It outlines various time series patterns, including horizontal, linear, seasonal, and cyclical patterns, and discusses forecasting methods such as moving averages, exponential smoothing, and linear regression. Learning objectives include identifying patterns, calculating forecast accuracy, and selecting appropriate forecasting models.

Uploaded by

daonga325
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views36 pages

Topic 7.S2

This document covers time series analysis and forecasting methods in banking and finance, focusing on quantitative techniques. It outlines various time series patterns, including horizontal, linear, seasonal, and cyclical patterns, and discusses forecasting methods such as moving averages, exponential smoothing, and linear regression. Learning objectives include identifying patterns, calculating forecast accuracy, and selecting appropriate forecasting models.

Uploaded by

daonga325
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

DATA ANALYTICS IN BANKING & FINANCE

TOPIC 6 – Time Series Analysis and


Forecasting

Department of Digital Banking – Faculty of Banking


Banking Academy of Vietnam
Contents

7.1 Time Series Patterns


7.2 Forecast Accuracy
7.3 Moving Averages and Exponential Smoothing
7.4 Using Linear Regression Analysis for Forecasting
Learning Objectives

After completing this topic, you will be able to:


LO 7-1 Identify an underlying pattern from a time-series plot of data.
LO 7-2 Calculate measures of forecasting accuracy including mean absolute
error, mean squared error, and mean absolute percentage error.
LO 7-3 Use measures of forecasting accuracy to choose an appropriate
forecasting model.
LO 7-4 Use simple techniques such as the naïve method and the average of all
historical data to forecast a time series that exhibits a horizontal pattern.
LO 7-5: Use smoothing techniques such as moving average and exponential
smoothing to forecast a time series that exhibits a horizontal pattern.
LO 7-6: Use simple linear regression to forecast a time series that exhibits a linear
trend.
LO 7-7: Use multiple linear regression analysis to develop a forecast for a time
series.
Introduction

Forecasting methods can be classified as qualitative or quantitative.

Qualitative methods involve the use of expert judgment to develop forecasts


when historical data on the variable being forecast is either unavailable or not
applicable.

Quantitative methods are used when past information about the forecast
variable is available, the information can be quantified, and the past may be
assumed as a prologue.

In this topic, we will focus exclusively on quantitative forecasting methods.


Time Series Patterns

A time series is a sequence of observations on a variable measured at successive


points in time or over successive periods of time, such as every hour, day, week,
month, or year, etc.
If a past data pattern can be expected to continue in the future, we can use it to
guide us in selecting an appropriate forecasting method.
The underlying data pattern is visualized using a time series plot, a graphical
presentation of the relationship with time graphed on the horizontal axis and the
time series variable on the vertical axis.
The objective of time series analysis is to uncover a pattern in the historical data
or time series.
Horizontal Pattern

• A horizontal pattern exists when the data fluctuate randomly around a


constant mean over time.
• Consider the 12 moths of data in the DATAfile: interest rate.
1 year savings interest
Month
rate (%)
2024-01 5.7
2024-02 7.0
2024-03 6.3
2024-04 7.7
2024-05 6.0
2024-06 5.3
2024-07 6.7
2024-08 6.0
2024-09 7.3
2024-10 6.7
2024-11 5.0
2024-12 7.3
Linear Trend Pattern

• A time series that exhibit show gradual shifts or movements to relatively higher
or lower values over a longer period of time it is said to have a trend pattern.
Year Interest income
2013 217
2014 318
2015 454
2016 576
2017 946
2018 765
2019 1029
2020 1668
2021 1587
2022 1415
2023 1411
2024 1568
Seasonal Pattern

• A seasonal pattern is a recurring pattern over successive periods of time.


• Time series data may exhibit seasonal patterns of less than one year in
duration.
Trend and Seasonal Pattern

• Time series including both trend and seasonality


• Example: Time series for quarterly remittances received through a bank
7.1 Cyclical Pattern

A cyclical pattern exists if the time series displays an alternating sequence of


points below and above the trend line lasting more than one year.
• Economic time series commonly exhibit cyclical behavior with regular runs of
observations below and above the trend line.
The cyclical component may be due to multi-year business cycles.
• Periods of moderate inflation followed by periods of rapid inflation can lead to
time series that alternate below and above a generally increasing trend line
(e.g., a time series for housing costs.)
Because business cycles are extremely difficult, if not impossible, to forecast,
cyclical effects are often combined with long-term trend effects and referred to
as trend-cycle effects.
7.2. Forecasting methods

Naïve Forecasting Method

Average of past values

Moving averages

Exponential smoothing
7.2.1. Naïve Forecasting Method

1 year savings
We begin developing forecasts for 1 Month
interest rate (%)
year saving interest rate included in
2024-01 5.7
the DATAfile: interest rate
2024-02 7.0
2024-03 6.3
For naïve forecasts, we simply set all 2024-04 7.7
forecasts to be the value of the last 2024-05 6.0
observation: 𝑦ො𝑡+1 = 𝑦𝑡 2024-06 5.3
2024-07 6.7
2024-08 6.0
2024-09 7.3
2024-10 6.7
2024-11 5.0
2024-12 7.3
7.2.2. Average of all past values

1 year savings Mont 1 year savings


Month
interest rate (%) h interest rate (%)

1 7
5.7 6.09 6.33
2 8
7.0 5.70 6.21 6.30
3 9
6.3 6.35 6.17 6.29
4 10
7.7 6.33 6.4 6.27
5 11
6.0 6.68 6.46 6.29
6 12
5.3 6.54 6.17 6.30
7.2.3. Moving Averages
7.2.3. Moving Average

The term ‘moving’ is used because every time a new observation becomes
available for the time series, it replaces the oldest observation in the equation
and a new average is computed.
• Thus, the periods over which the average is calculated, move with each
ensuing period.
To use moving averages to forecast a time series, we must first select the order k,
or the number of time series values to be included in the moving average.
The value of k is selected based on the number of past values that are considered
relevant.
• The greater the number of relevant past values, the larger the value selected
for k.
7.2.3. Moving Average

A time series with a horizontal pattern can shift to a new level over time.
A moving average will adapt to the new level of the series and resume providing
good forecasts in k periods.
➢ A smaller value of k will track shifts in a time series more quickly. The naïve
approach is actually a moving average with k = 1.
➢ Larger values of k are more effective to smooth out random fluctuations.
Thus, managerial judgment based on an understanding of the behavior of a time
series is helpful in choosing an appropriate value of 𝑘.
7.2.3. Three-month Moving Average Calculations

Month 1 year savings interest rate(%) Moving average calculations


1 5.7
2 7.0
3 6.3
4 7.7 6.33
5 6.0 7.00
6 5.3 6.67
7 6.7 6.33
8 6.0 6.00
9 7.3 6.00
10 6.7 6.67
11 5.0 6.67
12 7.3 6.33
7.2.4. Exponential Smoothing
7.2.4. Exponential Smoothing
7.2.4. Exponential Smoothing

1 year savings Mont 1 year savings


Month α = 0,2 α = 0,2
interest rate (%) h interest rate (%)

1 7
5.7 6.7 6.09
2 8
7.0 5.70 6.0 6.21
3 9
6.3 5.96 7.3 6.17
4 10
7.7 6.03 6.7 6.4
5 11
6.0 6.36 5.0 6.46
6 12
5.3 6.29 7.3 6.17
7.3. Forecast Error

Time Series Forecast


Week Value Forecast Error
1 17
2 21 17 4
3 19 21 -2
4 23 19 4
5 18 23 -5
6 16 18 -2
7 20 16 4
8 18 20 -2
9 22 18 4
10 20 22 -2
11 15 20 -5
12 22 15 7
Total 5
7.3.1. Mean Absolute Error

Abs. Value Forecast


Week Time Series Value Forecast Forecast Error Error

1 17

2 21 17 4 4

3 19 21 -2 2

4 23 19 4 4

5 18 23 -5 5

6 16 18 -2 2

7 20 16 4 4

8 18 20 -2 2

9 22 18 4 4

10 20 22 -2 2

11 15 20 -5 5

12 22 15 7 7

Totals 5 41
7.3.2. Mean Square Error

Week Time Series Value Forecast Forecast Error Squared Forecast Error

1 17

2 21 17 4 16

3 19 21 -2 4

4 23 19 4 16

5 18 23 -5 25

6 16 18 -2 4

7 20 16 4 16

8 18 20 -2 4

9 22 18 4 16

10 20 22 -2 4

11 15 20 -5 25

12 22 15 7 49

Totals 5 179
7.3.3. Mean Absolute Percentage Error

• Abs. Value Forecast %


Week Time Series Value Forecast Forecast Error Error

1 17
19
2 21 17 4 .05
10
3 19 21 -2 .53
17
4 23 19 4 .39
27
5 18 23 -5 .78
12
6 16 18 -2 .50
20
7 20 16 4 .00
11
8 18 20 -2 .11
18
9 22 18 4 .18
10
10 20 22 -2 .00
33
11 15 20 -5 .33

12 22 15 7 31.82
21
Totals 5 1.69
7.3.4. Average of All Past Values Forecast Error

Week Time Series Value Forecast Forecast Error

1 17

2 21 17 4

3 19 19 0

4 23 19 4

5 18 20 −2

6 16 19.6 −3.6

7 20 19 1

8 18 19.14 −1.14

9 22 19 3

10 20 19.33 0.67

11 15 19.4 −4.4

12 22 19 _ 3.00
7.3.5. Compare Forecasting Models

We can now proceed with the calculations of MAE, MSE, and MAPE as we did for
the naïve method. The results are summarized in the table below.
When comparing the accuracy of the two forecasting methods, we see that the
average of past values method is more accurate for each measure of forecasting
accuracy.

Naïve Method Average of Past Values


MAE 3.73 2.44
MSE 16.27 8.10
MAPE 19.24% 12.85%
7.4. Linear Trend Projection

We can use linear regression analysis to forecast a time series with a linear
trend as is the case for the previously introduced bank’s revenue growth rate
time series (DATAfile: bank’s revenue growth rate.)

Bank’s revenue growth rate


7.4. Linear Trend Equation: Line of Best Fit
7.4. Prediction with the Linear Trendline

The linear trend regression equation for the bank’s revenue growth rate time
series data is:
yt = 20.4 + 1.10t
The slope, b1=1.10 can be interpreted as an average growth of 1.1units per year
over the past 10 years.
We can then use the trend equation to project the trend component of the time
series for year 11 as:
y11 = 20.4 + 1.10*11 = 32.5
The linear model yields a revenue growth rate forecast of 32,5 % for next year.
Using the linear trend equation, we can also develop annual forecasts for two
and three years into the future as:
y12 = 20.4 + 1.10*12 = 33.6
y13 = 20.4 + 1.10*13 = 34.7
7.5. Other Regression-Based Forecasting Models
7.5. Seasonality Without Trend: Regression Equation

The general form of the equation relating the quarterly number of bank’s
revenue is:
yt = b0 + b1Qtr1 + b2Qtr2 + b3Qtr3
7.6 Seasonality With Trend

• We can model the remittance received through bank using three quarterly
dummy variables with the addition of a time period t to account for the linear
trend.
yt = b0 + b1Qtr1 + b2Qtr2 + b3Qtr3 + b4t
• Where
➢ t is the time period
➢ yt the forecast of remittance received through bank in period t
➢ Qtr1, Qtr2, Qtr3, are the seasonal dummy variables, defined as in the seasonality
without trend example.
7.7 Combining Causal Variables with Trend and
Seasonality Effects

Regression models are very flexible and can incorporate both causal variables
and time series effects.
Suppose we had a time series of several years of quarterly revenue data and
advertising expenditures for a single bank’s branch.
If we suspected that bank’s revenue were related to the causal variable
advertising expenditures and that bank’s revenue showed trend and seasonal
effects, we could incorporate each into a single model by combining the
approaches we have outlined as follows.
yt = b0 + b1Qtr1 + b2Qtr2 + b3Qtr3 + b4t + b5xt
Where xt are quarterly advertising expenditures.
7.8 Considerations in Using Regression in Forecasting

Although linear regression analysis allows for the estimation of complex


forecasting models, we must be cautious about using such models and guard
against the potential for overfitting our model to the sample data.
Many research studies have also shown that quantitative forecasting models
such as those presented in this chapter commonly outperform qualitative
forecasts made by “experts.”
Whether a regression approach provides a good forecast depends largely on
how well we are able to identify and obtain data for independent variables that
are closely related to the time series.
Part of the regression analysis procedure should focus on the selection of the set
of independent variables that provides the best forecasting model.
Summary: Determining the Best Forecasting Model to
Use

• A visual inspection can indicate whether seasonality appears to be a factor and


whether a linear or nonlinear trend seems to exist.
• For causal modeling, scatter charts can indicate whether strong relationships
exist between each independent variable and the dependent variable.
• If certain relationships appear totally random, this may lead to exclude the
corresponding independent variables from the model.
• While working with large data sets, it is recommended to divide the data into
training and validation sets, with training performed on the older data.
• Based on the errors produced by the different models for the validation set, the
model that minimizes MAE, MSE or MAPE is selected.
• There are software packages that will automatically select the best model.
THANK YOU FOR
WATCHING

Học viện Ngân hàng T: 1900 561 595 F: 1900 561 595
12 P. Chùa Bộc, P. Kim Liên, TP. Hà Nội E: truyenthong@[Link]
W: [Link]

You might also like