Você está na página 1de 41

# TREND ANALYSIS

Linear trend:
At = + t
Exponential trend:
At = t
Note that:
ln At = ln lnt
Gompertz trend:

At =

Parabolic
Trend

Exponential
Trend

Asymptotic
Trend

## Product life cycle: Gompertz trend

S-Curve Trend

EXAMPLE 4
(Blitz Beer Sales)

Pertiod
12
34
56
78
9
10

SaA
lets
44,,899100
45,,907100
55,,016000
55,,015700
55,,128400

Pertiod
1112
1134
1156
1178
1290

SaA
lets
55,,222800
55,,333800
55,,444600
55,,542900
55,,565000

6000

SALES

5500

5000

4500
0

10

12

PERIOD

14

16

18

20
4

## CAUSAL (ASSOCIATIVE) MODELS:

Linear Regression Model For Linear Trend
Technique for fitting a straight line to a set of
points to describe the relationship between two
variables:
^
Quantity being forecasted ( y )
Variable that influence the quantity being forecasted (x)
y^ = a + bx

## Estimated by least squares method

Minimizes sum of squared errors

## Least Squares Method

Actual observation
(y-value)

Deviation7

Deviation5

Deviation6

Deviation3
Deviation4
Deviation1
(error)

Deviation2

Trend line, ^y = a + bx

Time period
2011 Pearson Education, Inc. publishing as Prentice Hall

Figure 4.46

## Least Squares Method

Actual observation
(y-value)

Deviation7

Deviation5
Deviation3

Deviation6

## Least squares method

minimizes the sum of the
Deviation
squared errors (deviations)
4

Deviation1
(error)

Deviation2

Trend line, ^y = a + bx

Time period
2011 Pearson Education, Inc. publishing as Prentice Hall

Figure 4.47

## CAUSAL METHODS: LINEAR REGRESSION

MODEL FOR LINEAR TREND
Y = + T +
T is the independent (explanatory, stimulus,
exogenous, predictor) variable (in this case, time);
Y is the dependent (explained, response, endogenous,
predicted) variable;
is the y-intercept of the line Y = + T (value of
Y when T = 0);
is the slope of the regression line Y = + T
(increment in Y when T increases by 1);
is a random error term (deviation)
=Y ( + T)= Y-- T

## ESTIMATING THE MODEL

PARAMETERS
To find the line that best fits the data, we minimize
sum of squared errors
2 (yi - - ti)2
The value b of which minimizes the sum of the
errors squared is the slope of the regression line
The value a of which minimizes the sum of the
errors squared is the y-intercept of the regression
line
a + bT is the forecast at time T

## How Good Is the Regression

We need a relative measure of the degree of
variation of data about the regression line
Relative measure: compares the variation of Y
about the regression line with the variation of Y
without the regression line. This measure is called
coefficient of determination, R2
R2 is a descriptive measure of strength of the
regression relationship, a measure of how well the
regression line fits the data

11

## The three sources of variation

Total variation: variation in Y or AT from its mean (Y or AT)
before using the regression (Y Y or AT AT)
Total Variation = Explained Variation + Residual

## Explained Variation/Regression Deviation: What has been

eliminated from the total variation by using the regression
It is FT - AT

## Residual/Deviation: what is left after using the regression.

It is = AT FT
The coefficients of determination and of correlation:
R2 = Explained Variation / Total Variation
r = R 2 Coefficient of correlation
12

Coefficient of Determination: R2
0 <= R2 <= 1
R2 = 0.85
85% of the variability in Y or AT can be explained by the
regression equation
85% of the variability in Y or AT can be explained through
the knowledge of the independent variable X or T

## R2 >= 0.8 would indicate that the independent

variable is a good predictor of values of the
dependent variable.
0.25 <= R2 <= 0.8 would indicate a moderate
predictor
R2 <= 0.25 would indicate a poor predictor

13

Correlation
How strong is the linear relationship
between the variables?
Correlation does not necessarily imply
causality!
Coefficient of correlation, r, measures
degree of association
Values range from -1 to +1

## ADM 3301 ~ Rim Jaber

14

COEFFICIENT OF
CORRELATION VALUES, r

Perfect
Negative
Correlation

-1.0

Perfect
Positive
Correlation

No
Correlation

-.5

Increasing degree of
negative correlation

+.5

+1.0

Increasing degree of
positive correlation

## ADM 3301 ~ Rim Jaber

15

Correlation Coefficient
r=

nxy - xy
[nx2 - (x)2][ny2 - (y)2]

Correlation Coefficient
r=

nxy - xy
2
2
2
2
[nx
(x)
][ny
(y)
]
x

## (a) Perfect positive

correlation:
r = +1

(b) Positive
correlation:
0<r<1

(c) No correlation:

x
Fig. 4.10

## (d) Perfect negative x

correlation:
r = -1

EXCEL OUTPUT
(Blitz Beer Sales)
SUMMARY OUTPUT
Regression Statistics
|r|
Multiple R 0.9937799
R2
R Square 0.9875985

## Standard Error 25.426602

Observations
20
n

18

ANOVA
df
Regression
Residual
Total 19

EXCEL OUTPUT
(Blitz Beer Sales)
SS MS F
1
926737.78 926737.78 1433.4423
18
11637.218 646.51211
938375

a
Coefficients
Standard Error t Stat P-value
Intercept
4850.5263
11.811457
410.66284
X Variable 1 37.330827
0.9860014
37.860827
b

3.331E-37
1.294E-37

t Stat >= 2
P-value <= 0.05

19

## MINITAB OUTPUT FOR

BLITZ BEER SALES
MTB > Regress C2 1 C1;
The regression equation is
SALES = 4851 + 37.3 PERIOD
Predictor
Constant
PERIOD

Coef
Stdev
4850.53 11.81
37.33
0.99

t-ratio p
410.66 0.000
37.86 0.000

s = 25.43

R-sq = 98.8%

20

## MINITAB OUTPUT FOR

BLITZ BEER SALES
Analysis of Variance
SOURCE
Regression
Error
Total

DF
1
18
19

SS
926738
11637
938375

MS
F
p
926738 1433.44 0.000
647

Unusual Observations
Obs. PERIOD
7
7.0

SALES
5050.00

Fit
5111.84

Stdev.Fit
6.65

## R denotes an obs. with a large st. resid.

Residual
-61.84 R
21

SIGNIFICANCE
(Is the model useful?)
The regression will only be useful if there is a linear
relationship between T and Y (that is, if 0)
We must test the hypotheses:
H0: =0
H1: 0

## The t-ratio must be larger than t, where is the

desired significance level (generally, a t-ratio which
is greater than 2 in absolute value is significant)
The P-value must be small (smaller than 0.05)

22

CAVEATS
Variation ( around the regression line must be
random, with mean equal to 0 and standard
deviation (typically normally distributed).
Predictions outside the range of observed values
are not very accurate. Unfortunately, in
forecasting, you are almost always going out of
the observed range of T values.

23

Trend Not Fully
Accounted for

Desired Pattern

Error

Error

0
Time (Years)

Time (Years)

24

6000

SALES

5500

5000

4500
0

10

12

PERIOD

14

16

18

20
25

## Multiple Regression Analysis

If more than one independent variable is to be used in
the model, linear regression can be extended to
multiple regression to accommodate several
independent variables

y^ = a + b1x1 + b2x2
Computationally, this is quite complex and
generally done on the computer

26

TECHNIQUES FOR
SEASONALITY
Nave Method
Time Series Decomposition Models

27

Trend

Cyclical

Seasonal

Random

## ADM 3301 ~ Rim Jaber

28

Components of Demand

Trend
component
Seasonal peaks

Actual demand
line
Average demand
over 4 years

|
1

Random variation
|
|
2
3
Time (years)

|
4

Figure 4.1
29

## Time Series Decomposition Models

Any observed value in a time series is the product
(or sum) of time series components
Multiplicative model
At = Tt St Ct Rt
At = Tt + St + Ct + Rt
Objective
Isolate the four components of the model and
determine their effect on the time series in order
to be able to forecast the future

30

Quantity

Quantity

months
months

Multiplicative model

31

EXAMPLE 5
(Tackey Toys)

M
o1nthD
e
m
a
n
dM
o
n
t
h
D
e
m
a
n
dM
o
n
t
h
D
e
m
a
n
dM
o
n
t
h
D
e
m
a
n
d
54525 13 52978 25 52066 37 51141

14

## 23 5188134622 1145 5189174556 2267 6213922419 3389 6223624778

45 2252432292 1167 2253977250 2289 2275008732 4401 2267145405
67 1145651374 1189 1136367069 3301 1154589087 4423 1168527691
89 1155140088 2201 1188315294 3323 1280926092 4445 1282602874
1101 5833911888 2223 5863227998 3345 5862114796 4467 5864806684
12 72913 24 74194 36 75539 48 76531
32

DEMAND
90000

DEMAND

70000

50000

30000

10000

12

24

MONTH

36

48
33

At = Tt St Ct Rt

## Estimating seasonal indices, St ,from the

history of the series (At):
The seasonal indices are used:
To include seasonality in the forecasts
Or to remove such effects from the observed
values (Deseasonalize the data) in order to
get a clearer picture of the non seasonal
components.

34

## ISOLATING THE FOUR

COMPONENTS OF THE MODEL:
ESTIMATING St
A = T S C R
t

## Eliminate S R : centered moving average = T C .

The number of periods needed in a moving average (MA) is
equal to the number of seasons , N, involved
t

## If the number of period, N, is odd then MA(N) = Centered Moving

average (CMA)
MA(N) will be centered at the period: t + (N-1)/2

## If the number of period, N, is even then use MA(2) on the MA(N)

which will correspond to the Centered Moving Average (CMA)
monthly data 12-month moving average MA(12) then MA(2) on the
MA(12) (MA(2) = CMA)
quarterly data 4-quarter moving average MA (4) then MA(2) on
35 the
MA(4) (MA(2) = CMA)

## ISOLATING THE FOUR

COMPONENTS OF THE MODEL:
ESTIMATING St
A = T S C R
Eliminate S R : centered moving average = T C .
Calculate S R = (T S C R ) / (T C ) =
A / (centered moving average).
Calculate the seasonal indices S by averaging.
t

## Example: to compute the seasonal index for the month of

January, we average out all the value of S R that
corresponding to the month of January.
(1.41 + 1.33 + 1.29)/3 = 1.34
t

## Adjust the seasonal indices such as the total sum of the

indices over one year is equal to the number of period, N.

SEASONAL INDICES
2.2
2.0
1.8
1.6

S. I.

1.4
1.2
1.0
0.8
0.6
0.4
0.2
0

12

24

MONTH

36

48
37

## ISOLATING THE FOUR

COMPONENTS OF THE MODEL:
ESTIMATING Tt
A = T S C R
Eliminate S R : centered moving average = T C
Calculate S R = (T S C R ) / (T C ) =
A / (centered moving average).
Calculate the seasonal indices S by averaging.
Deseasonalize the data: deseasonalized demand = A / S
Determine a trend curve using regression:
y = deseasonalized demand
x or t = period.
t

## ADM 3301 ~ Rim Jaber

38

DESEASONALIZED DEMAND
WITH TREND
DES DEM

47000

42000

37000

32000
0

12

18

24

30

36

42

48

MONTH

39

## ISOLATING THE FOUR COMPONENTS

OF THE MODEL: ESTIMATING Ct
A = T S C R
t

## Eliminate S R : centered moving average = T C

Calculate S R = (T S C R ) / (T C ) =
A / (centered moving average).
Calculate the seasonal indices S by averaging.
Deseasonalize the data: deseasonalized demand = A / S
Determine a trend curve using regression:
y = deseasonalized demand and t = period.
t

Calculate C R = A / (T S )
t

40

## CYCLE AND RANDOM

VARIATIONS
1.15
1.10

C*R

1.05
1.00
0.95
0.90
0

12

18

24

30

36

42

48

MONTH

41

USING THE
MULTIPLICATIVE MODEL
F = T S C
Here, C 1, so we can neglect it).
t

90000
80000

DEMAND

70000
60000
50000
40000
30000
20000
10000
0

12

24

MONTH

36

48

42