0% found this document useful (0 votes)
26 views31 pages

Lesson 1 Introduction To Time Series

Uploaded by

GrinCurtis
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)
26 views31 pages

Lesson 1 Introduction To Time Series

Uploaded by

GrinCurtis
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
You are on page 1/ 31

Lesson 1: Introduction to Time Series

Learning Objectives

You will be able to do the following:


▪ Define "time series."
▪ Explain why time-series analysis is important.
▪ Identify time-series applications.
▪ Describe the components of time series.
▪ Describe and differentiate between additive, multiplicative, and
pseudoadditive time-series models.
▪ Use Python* to decompose a time-series dataset.

2
What Is a Time Series?

A sequence of data points organized in time


order.
▪ The sequence captures data at equally
spaced points in time.
▪ Data collected irregularly is not
considered a time series.

3
Time Series

Time-series data is common across many industries.


▪ Finance: stock prices, asset prices, macroeconomic factors
▪ E-Commerce: page views, new users, searches
▪ Business: transactions, revenue, inventory levels

4
Motivations for Using Time Series

Time-series methods are used to do the following:


▪ Understand the generative process underlying the observed data
▪ Fit a model in order to monitor or forecast a process

5
Applications of Time Series

Time-series analysis is used in the following:


▪ Economic forecasting
▪ Stock-market analysis
▪ Demand planning and forecasting
▪ Anomaly detection
▪ And much more

7
Economic Forecasting

Macroeconomic predictions:

▪ World Trade Organization does time


series forecasting to predict levels
of international trade.

▪ Federal Reserve uses time-series


forecasts of the economy to set interest
rates.
Image source: https://commons.wikimedia.org/wiki/File:Ever_Given_container_ship.jpg
Source: https://www.econ-jobs.com/research/36056-Forecasting-international-trade-A-time-series-approach.pdf
Source: https://www.federalreserve.gov/pubs/feds/2009/200910/200910pap.pdf

8
Demand Forecasting

Used to predict demand, both overall and at more granular levels

▪ Amazon and other e-commerce


companies use time-series modeling to
predict demand at a product-geography
level.

▪ Helps meet customer needs (fast


shipping) and reduce inventory waste.
Image source: https://commons.wikimedia.org/wiki/File:Amazon_España_por_dentro_(20).jpg
Source: https://www.theverge.com/2014/1/18/5320636/amazon-plans-to-ship-your-packages-before-you-even-buy-them

9
Anomaly Detection

Particular kind of time-series analysis for detecting anomalies in time series

▪ Widely in manufacturing to detect defects


and target preventive maintenance

▪ Now, with new IoT devices, techniques


spreading to other machinery-heavy
industries, such as petroleum and gas

Image source: https://en.wikipedia.org/wiki/Oil_platform#/media/File:Oil_platform_P-51_(Brazil).jpg


Source: https://arxiv.org/pdf/1607.02480.pdf
Petroleum source: www.mdpi.com/1424-8220/15/2/2774/pdf

10
Time-Series Components

A time series has three components:


▪ Trend – long-term direction
▪ Seasonality – periodic behavior
▪ Residual – irregular fluctuations

12
Trend

Trend captures the general direction of the time series.


▪ For example, increasing job growth year over year despite seasonal
fluctuations.
▪ Trend can be increasing, decreasing, or constant.
▪ It can increase or decrease in different ways (linearly, exponentially, or in
other ways).

13
Time Series
Trend

14
Seasonality

Seasonality captures effects that occur with specific frequency. It can be driven
by many factors.
▪ Naturally occurring events, such as weather fluctuations caused by time of year
▪ Business or administrative procedures, such as start and end of a school year
▪ Social or cultural behavior, such as holidays or religious observances
▪ Fluctuations due to calendar events, such as the number of Mondays per
month for trading or holidays that shift from year to year (Easter, Chinese
New Year)

15
16
Residuals

Residuals are the random fluctuations left over after trend and seasonality are
removed.
▪ They are what is left over after trend and seasonality are removed from the
original time series.
– You should not see a trend or seasonal pattern in the residual.
▪ They represent short-term fluctuations.
▪ They’re either random or a portion of the trend or seasonality components
was missed in the decomposition.

17
18
Decomposition Models

Time-series components can be decomposed with the following models:


▪ Additive decomposition
▪ Multiplicative decomposition
▪ Pseudoadditive decomposition

20
Additive Model

Additive models assume that the observed time series is the sum of its
components.
▪ Observation = Trend + Seasonality + Residual
▪ Additive models are used when the magnitudes of the seasonal and residual
values are independent of trend.

21
22
Multiplicative Model

The observed time-series multiplicative models assume that the observed


time series is the product of its components.
▪ Observation = Trend * Seasonality * Residual
▪ It is possible to transform a multiplicative model to an additive by applying a
log transformation.
– log(Time*Seasonality*Residual) = log(Time) + log(Seasonality) +
log(Residual)
▪ Multiplicative models are used when the magnitudes of the seasonal and
residual values fluctuate with trend.

23
24
Additive vs. Multiplicative Models

The magnitudes of the seasonal and The magnitudes of the seasonal and
residual values fluctuate with trend. residual values are independent of trend.

25
Pseudoadditive Model

Pseudoadditive models combine elements of the additive and multiplicative


models.
▪ Useful when time series values are close to or equal to zero and you require a
multiplicative model.
▪ Division by zero becomes a problem in multiplicative models when this is the
case.
▪ For example, rewriting the model as follows:
– Ot = Tt + Tt(St – 1) + Tt(Rt – 1) = Tt(St + Rt – 1)

26
How to Decompose a Time Series

Of the many ways to decompose a time series, these are the most common:
▪ Single, double, or triple exponential smoothing
▪ Locally estimated scatterplot smoothing (LOESS)
▪ Frequency-based methods common in signal processing
▪ More on these methods in future lessons!

27
Using Python to Decompose Time Series

Next up is a look at applying these concepts in Python


▪ See notebook entitled Introduction_to_Time_Series_student.ipynb

28
Learning Objectives Recap

In this session you learned how to do the following:


▪ Define "time series"
▪ Explain why time series analysis is important
▪ Identify time series applications
▪ Describe the components of time series
▪ Describe and differentiate between additive, multiplicative, and
pseudoadditive time series models
▪ Use Python to decompose a time-series dataset

29
Legal Notices and Disclaimers
This presentation is for informational purposes only. INTEL MAKES NO WARRANTIES, EXPRESS OR IMPLIED, IN THIS
SUMMARY.

Intel technologies’ features and benefits depend on system configuration and may require enabled hardware, software
or service activation. Performance varies depending on system configuration. Check with your system manufacturer or
retailer or learn more at intel.com.

Sample source code is released under the Intel Sample Source Code License Agreement.

Intel, the Intel logo, the Intel. Experience What’s Inside logo, and Intel. Experience What’s Inside are trademarks of Intel
Corporation in the U.S. and/or other countries.

*Other names and brands may be claimed as the property of others.

Copyright © 2018, Intel Corporation. All rights reserved.

30

You might also like