+ All Categories
Home > Documents > Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1...

Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1...

Date post: 21-Aug-2020
Category:
Upload: others
View: 0 times
Download: 0 times
Share this document with a friend
38
Foundations - 1 Temporal Information Retrieval Time-series Analysis, Forecasting
Transcript
Page 1: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Foundations - 1

Temporal Information Retrieval

Time-series Analysis, Forecasting

Page 2: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Time Series• An ordered sequence of values (data points) of

variables at equally spaced time intervals

Page 3: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Time Series Components

Page 4: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Forecasting• Forecasting using time-series a classical task to predict the future

values based on past observations

• Heavily used in many domains for forecasting:

• Stock prices

• Market adoption

• Weather conditions

• Sales of articles

• Environmental carbon footprint

Page 5: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Forecasting• Given a series of observations {yT} predict forecast

the observation at T+h

Given that observations have been made until time t

Page 6: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Forecasting• Given a series of observations {yT} predict forecast

the observation at T+h

yt+h|t = yt

Given that observations have been made until time t

Page 7: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Forecasting• Given a series of observations {yT} predict forecast

the observation at T+h

yt+h|t = yt

forecast for time t+h

Given that observations have been made until time t

Page 8: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Forecasting• Given a series of observations {yT} predict forecast

the observation at T+h

yt+h|t = yt

forecast for time t+h

observed value at tGiven that observations

have been made until time t

Page 9: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Forecasting

• What is the forecast for the next time point ?

Page 10: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Forecasting

• What is the forecast for the next time point ?

• Simple Average

• Moving Average

• Linear Regression

• Weighted Average

Idea : More weights to recent data

Page 11: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Simple Exponential Smoothing

yt+1|t = ↵yt + ↵(1� ↵)yt�1 + ↵(1� ↵)2yt�2 + · · · ,

• Forecast for time t+1 given that t values have been observed

• Exponentially decreasing weights

Page 12: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Simple Exponential Smoothing

yt+1|t = ↵yt + ↵(1� ↵)yt�1 + ↵(1� ↵)2yt�2 + · · · ,

• Forecast for time t+1 given that t values have been observed

• Exponentially decreasing weights

smoothing parameter in [0,1]

Page 13: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Simple Exponential Smoothing

yt+1|t = ↵yt + ↵(1� ↵)yt�1 + ↵(1� ↵)2yt�2 + · · · ,

• Forecast for time t+1 given that t values have been observed

• Exponentially decreasing weights

smoothing parameter in [0,1]

Page 14: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

SES: Component Form

yt+1|t = ↵yt + ↵(1� ↵)yt�1 + ↵(1� ↵)2yt�2 + · · · ,

Component Form

yt+1|t = ↵yt + (1� ↵)yt|t�1

weighted average form

Interpretation: SES is the linear combination of last observed value and last forecast value

Page 15: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

SES: Component Form

yt+1|t = ↵yt + ↵(1� ↵)yt�1 + ↵(1� ↵)2yt�2 + · · · ,

Component Form

yt+1|t = ↵yt + (1� ↵)yt|t�1

weighted average form

forecast for time t+1

Interpretation: SES is the linear combination of last observed value and last forecast value

Page 16: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

SES: Component Form

yt+1|t = ↵yt + ↵(1� ↵)yt�1 + ↵(1� ↵)2yt�2 + · · · ,

Component Form

yt+1|t = ↵yt + (1� ↵)yt|t�1

weighted average form

forecast for time tforecast for time t+1

Interpretation: SES is the linear combination of last observed value and last forecast value

Page 17: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Simple Exponential Smoothingyt+1|t = ↵yt + (1� ↵)yt|t�1

`t�1 = yt|t�1

`t = ↵yt + (1� ↵)`t�1 component form

Page 18: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Simple Exponential Smoothingyt+1|t = ↵yt + (1� ↵)yt|t�1

`t�1 = yt|t�1

`t = ↵yt + (1� ↵)`t�1 component form

is the level (or the smoothed value) of the series at time t

Page 19: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Simple Exponential Smoothingyt+1|t = ↵yt + (1� ↵)yt|t�1

`t�1 = yt|t�1

`t = ↵yt + (1� ↵)`t�1

`t = `t�1 + ↵(yt � `t�1)

= `t�1 + ↵eterror correction form

component form

is the level (or the smoothed value) of the series at time t

Page 20: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Simple Exponential Smoothingyt+1|t = ↵yt + (1� ↵)yt|t�1

`t�1 = yt|t�1

`t = ↵yt + (1� ↵)`t�1

`t = `t�1 + ↵(yt � `t�1)

= `t�1 + ↵eterror correction form

component form

is the level (or the smoothed value) of the series at time t

Interpretation: SES is sum of last observed value and smoothed error from the last measurement

Page 21: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Simple Exponential Smoothing

yt+1|t = ↵yt + ↵(1� ↵)yt�1 + ↵(1� ↵)2yt�2 + · · · ,

`t = ↵yt + (1� ↵)`t�1

error correction form

Weighted Average form

`t = `t�1 + ↵(yt � `t�1)

component form

SES gives us the forecast for level

Page 22: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Simple Exponential Smoothing

`t = ↵yt + (1� ↵)`t�1 component form

in action

since no prior info.

exists

Query vol.for

“hannover”

Page 23: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Simple Exponential Smoothing

`t = ↵yt + (1� ↵)`t�1 component form

in action

since no prior info.

exists

Query vol.for

“hannover”

Page 24: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Choice of Weights• To estimate the smoothing parameter, forecasts are

computed for equal to .1, .2, .3, …, .9 and the sum of squared forecast error is computed for each

• The smallest Mean Square Error (MSE) is chosen for use in producing the future forecasts.

1

n

nX

t=1

(yt � yt)2

et = yt � yterror

Page 25: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Goodness of Forecast

• Root Mean Squared Error (RMSE) :

• Mean Absolute Error (MAE):

• Mean Absolute Percentage Error (MAPE):

vuut 1

n

nX

t=1

e2t

1

n

nX

t=1

|et|

100%

n

nX

t=1

����etyt

����

Page 26: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Holt’s Model

`t = ↵yt + (1� ↵)`t�1 simple exponential smoothing

SES responds slow to trend data

upward trend

Holt’s model explicitly models Trend alongwith Level

time

query volume

Double Exponential Smoothing

Page 27: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Holt’s Model

bt = �⇤(`t � `t�1) + (1� �⇤)bt�1

Trend Equation

`t = ↵yt + (1� ↵)(`t�1 + bt�1)Level Equation

Adds a growth factor (or trend factor) to the smoothing equation as a way of adjusting for the trend.

Double Exponential Smoothing

Page 28: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Holt’s Model

bt = �⇤(`t � `t�1) + (1� �⇤)bt�1

Trend Equation

yt+h|t = `t + hbtForecast Equation

`t = ↵yt + (1� ↵)(`t�1 + bt�1)Level Equation

Adds a growth factor (or trend factor) to the smoothing equation as a way of adjusting for the trend.

Double Exponential Smoothing

Page 29: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Choice of Weights

• To weights and can be selected subjectively or by minimizing a measure of forecast error such as RMSE

• Large weights result in more rapid changes in the component. Small weights result in less rapid changes.

↵ �

Page 30: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Holt-Winters Model

• Winter’s exponential smoothing model is the second extension of the basic Exponential smoothing model.

• It is used for data that exhibit both trend and seasonality.

• It is a three parameter model that is an extension of Holt’s method.

• An additional equation adjusts the model for the seasonal component.

Triple Exponential Smoothing

Page 31: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Holt-Winters Model

st = �(yt � `t�1 � bt�1) + (1� �)st�m,

Triple Exponential Smoothing

Page 32: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Holt-Winters Model

yt+1|t = `t + hbt + st�m+h+m

`t = ↵(yt � st�m) + (1� ↵)(`t�1 + bt�1)

Level Equation

st = �(yt � `t�1 � bt�1) + (1� �)st�m,

Seasonality Equation

bt = �⇤(`t � `t�1) + (1� �⇤)bt�1Trend Equation

Triple Exponential Smoothing

Page 33: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Which smoothing model to use ?

Page 34: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Which smoothing model to use ?

Page 35: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Summary• Forecasting of time-series and their applications in IR

applications

• Components of a Time series - Level, Trend and Seasonality

• Exponential Smoothing Methods vs Averaging Methods

• Level oriented Methods - Simple Exponential Smoothing

• Adding Trend - Double Exponential Smoothing

• Adding Seasonality - Triple Exponential Smoothing

Page 36: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

References

• Forecasting: principles and practice. (Chapter 7)

• https://www.otexts.org/fpp/

• Introduction to Time Series and Forecasting.

• http://www.masys.url.tw/Download/2002-Brockwell-Introduction%20Time%20Series%20and%20Forecasting.pdf

Page 37: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Projects• Each project has a mentor who you should co-

ordinate with

• Mentor provides you a concrete task definition and data

• Each mentor tracks your progress and guides you

• Drop an email to the mentor to fix an appointment

• Bitbucket vs SVN..Vote next week

http://www.l3s.de/~anand/tir14/projects.html

Page 38: Foundations - 1anand/tir14/lectures/ws14-tir-foundations-1.pdf · Holt’s Model ` t = ↵y t +(1 ↵)` t1 simple exponential smoothing SES responds slow to trend data upward trend

Projects• Temporal and Phrase-based Indexing - Avishek

• Temporal Retrieval Models - Jaspreet

• Temporal Query Enrichments - Avishek

• Crawling for Temporal Collections - Gerhard

• Temporal Extraction - Helge

http://www.l3s.de/~anand/tir14/projects.html


Recommended