You are on page 1of 29

Assignment #2: Internet Field

Trip
“Forecasting”
Mae Powell-Hunt
Professor Joseph
Quantitative Methods

1 1
Forecasting Definition

1. To estimate or calculate in advance, especially to predict


(weather conditions) by analysis of meteorological data.

2. To serve as an advance indication of; foreshadow: price


increases that forecast inflation. (Answers Corporation, 2011)

2 2
Forecasting Methods two Types

 Qualitative Methods has three


DELPHI TECHNIQUE, SCENARIO WRITING, and SUBJECTIVE APPROACH.

 Quantitative Methods has two


TIME SERIES METHODS OF FORECASTING and CAUSAL METHOD OF
FORECASTING.

3 3
QUANTITATIVE FORECASTING
METHODS
TIME SERIES FORECASTING METHODS

In the following topics, we will review techniques that are


useful for analyzing time series data, that is, sequences of
measurements that follow non-random orders. Unlike the
analyses of random samples of observations that are discussed in
the context of most other statistics, the analysis of time series
is based on the assumption that successive values in the data file
represent consecutive measurements taken at equally spaced
time intervals.

4
QUANTITATIVE FORECASTING
METHODS
TIME SERIES FORECASTING METHODS

Two Main Goals


 There are two main goals of time series analysis: (a) identifying the
nature of the phenomenon represented by the sequence of observations,
and (b) forecasting (predicting future values of the time series variable).
Both of these goals require that the pattern of observed time series data is
identified and more or less formally described. Once the pattern is
established, we can interpret and integrate it with other data (i.e., use it in
our theory of the investigated phenomenon, e.g., seasonal commodity
prices). Regardless of the depth of our understanding and the validity of
our interpretation (theory) of the phenomenon, we can extrapolate the
identified pattern to predict future events. (Interactive Data Corp ,2011)

5
QUANTITATIVE FORECASTING METHODS
TIME SERIES FORECASTING METHODS

 time series forecasting methods are based on analysis of historical data (time
series: a set of observations measured at successive times or over successive
periods). They make the assumption that past patterns in data can be used to
forecast future data points.
 1. moving averages (simple moving average, weighted moving average):
forecast is based on arithmetic average of a given number of past data points
 2. exponential smoothing (single exponential smoothing, double exponential
smoothing): a type of weighted moving average that allows inclusion of
trends, etc.
 3. mathematical models (trend lines, log-linear models, Fourier series, etc.):
linear or non-linear models fitted to time-series data, usually by regression
methods
 4. Box-Jenkins methods: autocorrelation methods used to identify
underlying time series and to fit the "best" model ( FORECASTING, Unknown)

6 6
QUANTITATIVE FORECASTING METHODS
TIME SERIES FORECASTING METHODS

 COMPONENTS OF TIME SERIES DEMAND


 1. average: the mean of the observations over time
 2. trend: a gradual increase or decrease in the average over time
 3. seasonal influence: predictable short-term cycling behaviour due to
time of day, week, month, season, year, etc.
 4. cyclical movement: unpredictable long-term cycling behaviour due to
business cycle or product/service life cycle
 5. random error: remaining variation that cannot be explained by the
other four components (FORECASTING, Unknown)

7 7
QUANTITATIVE FORECASTING
METHODS
TIME SERIES FORECASTING METHODS

There are several different types of moving averages, which we are going to
explore here, all of which are used by traders to try and smooth out the price
action of a financial instrument, and get a better feel for the longer term
direction without all the noise that is often associated with just looking at the
price. In addition to getting a better feel for the longer term trend of a
financial instrument, moving averages are also used to spot potential support
and resistance levels, and are often used in conjunction with one another to
generate buy and sell signals.
The two most popular types of moving averages are the Simple Moving
Average (SMA) and the Exponential Moving Average (EMA). These
moving averages can be used to identify the direction of the trend or define
potential support and resistance levels. ( Interactive Data Corp ,1999-2011)

8 8
QUANTITATIVE FORECASTING
METHODS
TIME SERIES FORECASTING METHODS

A simple moving average is formed by computing the average price


of a security over a specific number of periods. Most moving
averages are based on closing prices. A 5-day simple moving average
is the five day sum of closing prices divided by five. As its name
implies, a moving average is an average that moves. Old data is
dropped as new data comes available. This causes the average to
move along the time scale. Below is an example of a 5-day moving
average evolving over three days. (Interactive Data Corp , 1999-2011)

9
QUANTITATIVE FORECASTING
METHODS
TIME SERIES FORECASTING METHODS

Exponential Moving Average & Calculation

Daily Closing Prices: 11,12,13,14,15,16,17 First day of 5-day


SMA: (11 + 12 + 13 + 14 + 15) / 5 = 13 Second day of 5-day
SMA: (12 + 13 + 14 + 15 + 16) / 5 = 14 Third day of 5-day
SMA: (13 + 14 + 15 + 16 + 17) / 5 = 15

(Interactive Data Corp ,1999-2011)

10
QUANTITATIVE FORECASTING
METHODS
TIME SERIES FORECASTING METHODS

Exponential Moving Average & Calculation


The first day of the moving average simply covers the last five days.
The second day of the moving average drops the first data point (11)
and adds the new data point (16). The third day of the moving
average continues by dropping the first data point (12) and adding
the new data point (17). In the example above, prices gradually
increase from 11 to 17 over a total of seven days. Notice that the
moving average also rises from 13 to 15 over a three day calculation
period. Also notice that each moving average value is just below the
last price. For example, the moving average for day one equals 13
and the last price is 15. Prices the prior four days were lower and this
causes the moving average to lag (Interactive Data Corp ,1999-2011)

11
QUANTITATIVE FORECASTING
METHODS
TIME SERIES FORECASTING METHODS

Exponential Moving Average & Calculation

Exponential moving averages reduce the lag by applying more weight to


recent prices. The weighting applied to the most recent price depends on the
number of periods in the moving average. There are three steps to
calculating an exponential moving average. First, calculate the simple
moving average. An exponential moving average (EMA) has to start
somewhere so a simple moving average is used as the previous period's
EMA in the first calculation. Second, calculate the weighting multiplier.
Third, calculate the exponential moving average. The formula below is for a
10-day EMA. (Interactive Data Corp ,1999-2011)

12
QUANTITATIVE FORECASTING
METHODS
TIME SERIES FORECASTING METHODS

Exponential Moving Average & Calculation

SMA: 10 period sum / 10 Multiplier: (2 / (Time periods + 1) ) = (2 / (10 + 1)


) = 0.1818 (18.18%) EMA: {Close - EMA(previous day)} x multiplier +
EMA(previous day). (Interactive Data Corp ,1999-2011)

13
QUANTITATIVE FORECASTING
METHODS
TIME SERIES FORECASTING METHODS

 Exponential Moving Average & Calculation

A 10-period exponential moving average applies an 18.18% weighting to


the
most recent price. A 10-period EMA can also be called an 18.18% EMA. A
20-period EMA applies a 9.52% weighing to the most recent price (2/(20+1)
= .0952). Notice that the weighting for the shorter time period is more than
the weighting for the longer time period. In fact, the weighting drops by half
every time the moving average period doubles. (Interactive Data Corp ,1999-2011)

14
QUANTITATIVE FORECASTING
METHODS
TIME SERIES FORECASTING METHODS

Exponential Moving Average & Calculation

Below is a spreadsheet example of a 10-day simple moving average and


a 10-day exponential moving average for Intel. Simple moving averages
are straight forward and require little explanation. The 10-day average
simply moves as new prices become available and old prices drop off.
The exponential moving average starts with the simple moving average
value (22.22) in the first calculation. After the first calculation, the
normal formula takes over. (Interactive Data Corp ,1999-2011)

15
QUANTITATIVE FORECASTING
METHODS
TIME SERIES FORECASTING METHODS

Exponential Moving Average & Calculation

Because an EMA begins with a simple moving average, its true value
will not be realized until 20 or so periods later. In other words, the
value on the excel spreadsheet may differ from the chart value because
of the short look-back period. This spreadsheet only goes back 30
periods, which means the affect of the simple moving average has had
20 periods to dissipate. Stockcharts.com goes back 250-periods for its
calculations so the effects of the simple moving average in the first
calculation have fully dissipated (Interactive Data Corp ,1999-2011)

16
QUALITATIVE FORECASTING
METHODS
 qualitative forecasting methods are based on educated opinions of
appropriate persons
 1. delphi method: forecast is developed by a panel of experts who
anonymously answer a series of questions; responses are fed back to
panel members who then may change their original responses
 - very time consuming and expensive
 - new groupware makes this process much more feasible
 2. market research: panels, questionnaires, test markets, surveys, etc.
 3. product life-cycle analogy: forecasts based on life-cycles of similar
products, services, or processes
 4. expert judgement by management, sales force, or other
knowledgeable persons (FORECASTING, Unknown)

17 17
QUALITATIVE FORECASTING
METHODS
Trend Analysis

There are no proven "automatic" techniques to identify trend components in


the time series data; however, as long as the trend is monotonous
(consistently increasing or decreasing) that part of data analysis is typically
not very difficult. If the time series data contain considerable error, then the
first step in the process of trend identification is smoothing. (StatSoft Electronic
Statistics Textbook, Unknown)
Unknown

18 18
QUALITATIVE FORECASTING
METHODS
Trend Analysis Smoothing
Smoothing always involves some form of local averaging of data such that
the nonsystematic components of individual observations cancel each other
out. The most common technique is moving average smoothing which
replaces each element of the series by either the simple or weighted average
of n surrounding elements, where n is the width of the smoothing "window"
(see Box & Jenkins, 1976; Velleman & Hoaglin, 1981). Medians can be
used instead of means. The main advantage of median as compared to
moving average smoothing is that its results are less biased by outliers
(within the smoothing window). Thus, if there are outliers in the data (e.g.,
due to measurement errors), median smoothing typically produces smoother
or at least more "reliable" curves than moving average based on the same
window width. The main disadvantage of median smoothing is that in the
absence of clear outliers it may produce more "jagged" curves than moving
average and it does not allow for weighting. .(StatSoft Electronic Statistics Textbook,
Unknown)

19
QUALITATIVE FORECASTING METHODS
Trend Analysis Smoothing

In the relatively less common cases (in time series data), when the
measurement error is very large, the distance weighted least squares
smoothing or negative exponentially weighted smoothing techniques can be
used. All those methods will filter out the noise and convert the data into a
smooth curve that is relatively unbiased by outliers (see the respective
Sections on each of those methods for more details). Series with relatively
few and systematically distributed points can be smoothed with bicubic
splines. .(StatSoft Electronic Statistics Textbook, Unknown)
Unknown

20 20
QUALITATIVE FORECASTING METHODS
Trend Analysis Smoothing

Fitting a function. Many monotonous time series data can be adequately


approximated by a linear function; if there is a clear monotonous nonlinear
component, the data first need to be transformed to remove the nonlinearity.
Usually a logarithmic, exponential, or (less often) polynomial function can
be used. .(StatSoft Electronic Statistics Textbook, Unknown)

21
QUALITATIVE FORECASTING METHODS
Trend Analysis of Seasonality

Seasonal dependency (seasonality) is another general component of the time


series pattern. The concept was illustrated in the example of the airline
passengers data above. It is formally defined as correlational dependency of
order k between each i'th element of the series and the (i-k)'th element
(Kendall, 1976) and measured by autocorrelation (i.e., a correlation between
the two terms); k is usually called the lag. If the measurement error is not
too
large, seasonality can be visually identified in the series as a pattern that
repeats every k elements. .(StatSoft Electronic Statistics Textbook, Unknown)
Unknown

22 22
QUALITATIVE FORECASTING METHODS
Trend Analysis of Seasonality

Autocorrelation correlogram. Seasonal patterns of time series can be


examined via correlograms. The correlogram (autocorrelogram) displays
graphically and numerically the autocorrelation function (ACF), that is,
serial correlation coefficients (and their standard errors) for consecutive lags
in a specified range of lags (e.g., 1 through 30). Ranges of two standard
errors for each lag are usually marked in correlograms but typically the size
of auto correlation is of more interest than its reliability (see Elementary
Concepts) because we are usually interested only in very strong (and thus
highly significant) autocorrelations. .(StatSoft Electronic Statistics Textbook, Unknown)

23
QUALITATIVE FORECASTING METHODS
Trend Analysis of Seasonality

Examining correlograms. While examining correlograms, you should keep


in mind that autocorrelations for consecutive lags are formally dependent.
Consider the following example. If the first element is closely related to the
second, and the second to the third, then the first element must also be
somewhat related to the third one, etc. This implies that the pattern of serial
dependencies can change considerably after removing the first order auto
correlation (i.e., after differencing the series with a lag of 1). (StatSoft Electronic
Statistics Textbook, Unknown)

24
QUALITATIVE FORECASTING METHODS
Trend Analysis of Seasonality

Partial autocorrelations. Another useful method to examine serial dependencies is to


examine the partial autocorrelation function ( PACF) - an extension of
autocorrelation, where the dependence on the intermediate elements (those within
the
lag) is removed. In other words the partial autocorrelation is similar to
autocorrelation, except that when calculating it, the (auto) correlations with all the
elements within the lag are partialled out (Box & Jenkins, 1976; see also McDowall,
McCleary, Meidinger, & Hay, 1980). If a lag of 1 is specified (i.e., there are no
intermediate elements within the lag), then the partial autocorrelation is equivalent to
auto correlation. In a sense, the partial autocorrelation provides a "cleaner" picture of
serial dependencies for individual lags (not confounded by other serial
dependencies). (StatSoft Electronic Statistics Textbook, Unknown)

25
QUALITATIVE FORECASTING METHODS
Trend Analysis of Seasonality

Removing serial dependency. Serial dependency for a particular lag of k


can be removed by differencing the series, that is converting each i'th
element of the series into its difference from the (i-k)''th element. There are
two major reasons for such transformations. (StatSoft Electronic Statistics Textbook,
Unknown)

26
QUALITATIVE FORECASTING METHODS
Trend Analysis of Seasonality

First, we can identify the hidden nature of seasonal dependencies in the


series. Remember that, as mentioned in the previous paragraph,
autocorrelations for consecutive lags are interdependent. Therefore,
removing some of the autocorrelations will change other auto correlations,
that is, it may eliminate them or it may make some other seasonalities more
apparent. (StatSoft Electronic Statistics Textbook, Unknown)
Unknown

27 27
Reference
Interactive Data Corp ,(1999-2011), StockCharts.com Chat School,. Moving Averages

http://stockcharts.com/school/doku.php?id=chart_school:technical_indicators:moving_averages#sim
ple_moving_averag

StatSoft Electronic Statistics Textbook, Time Series Analysis, retrieved on 5-7-11, from
http://www.statsoft.com/textbook/time-series-analysis/

David Waring,(2007), Informed trades, Introduction to Simple and exponential moving


average (EMA) forecasting model and calculation retrieved on 5-7-11, from
http://www.informedtrades.com/3754-introduction-simple-exponential-moving-average-ema-forecas
ting-model-calculation.html

FORECASTING, Learning Objectives, Retrieved on 5-7-11, from


http://www.uoguelph.ca/~dsparlin/forecast.htm

Answers Corporation, (2011), The American Heritage Dictionary of the English Language, 4 th
edition, forecast, retrieved on 5-7-11, from http://www.answers.com/topic/forecast
28 28
The End

29 29

You might also like