0% found this document useful (0 votes)
6 views7 pages

Class 6

The document discusses the Least Square Method for fitting a linear trend line to time series data, emphasizing its mathematical basis and the conditions it satisfies. It outlines the process for calculating the constants of the trend line and highlights the merits and demerits of the method. Additionally, it provides illustrations and examples to demonstrate the application of the method in predicting future values.

Uploaded by

Kaustuv
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)
6 views7 pages

Class 6

The document discusses the Least Square Method for fitting a linear trend line to time series data, emphasizing its mathematical basis and the conditions it satisfies. It outlines the process for calculating the constants of the trend line and highlights the merits and demerits of the method. Additionally, it provides illustrations and examples to demonstrate the application of the method in predicting future values.

Uploaded by

Kaustuv
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/ 7

Business Mathematics and Statistics

NCWEB Hansraj Centre

E-Class on 11/04/2020

By Ms.Komal Chhikara

Bcom Sem II, Section A

Learning Goals:

In this class we will discuss:

 Fitting of linear trend line using principle of least squares.

Least Square Method

This is also known as straight line method. This method is most commonly used in research to
estimate the trend of time series data, as it is mathematically designed to satisfy two conditions.
They are:

1) Sum of (Y + Yc) = 0 and

2) Sum of (𝑌 + 𝑌𝑐)2 = Least

The straight line method gives a line of best fit on the given data. The straight line which can
satisfy the above conditions and make use of regression equation is given by:

Yc = a+ bX

where X represents time variable, Y. is the dependent variable for which trend values are to be
calculated, a and b are the constants of the straight line to be found by the method of least
squares. Constant a is the Y-intercept.

The values of constant, ‘a’ and ‘b’ are determined by the following two normal equations.

∑𝑌 = 𝑛𝑎 + 𝑏∑𝑌 − − − − − (1)

∑𝑥𝑦 = 𝑎∑𝑥 + 𝑏∑𝑥 2 − − − −(2)

The process of finding values of constants a and b can be made simple by using a shortcut
method, that is, by taking the origin year in such a way that it gives the toal of ‘x’ (∑x) equal to
‘zero’. This becomes possible if we take the median year as origin period. Thus, the negative
values in the first half of the series balance out the positive values in the second half. Thus, the
earlier normal equation shall be changed as follows, with reference to ∑x = 0.

∑y = a (as ∑ bx becomes zero)

∑xy = b∑𝑥 2 (as a∑x becomes zero)

Therefore, the values of two constants are obtained by the following formulae:
∑𝑦 ∑ 𝑥𝑦
𝑎= and 𝑏 =
𝑁 𝑥2

It is to be noted that when the number of time units involved is even, the point of origin will have
to be chosen between the two middle time units.

Merits and demerits of method of Least square

Merits:

(i) This is a mathematical method of measuring trend and is free from subjectivity.

(ii) It provides the line of ‘best fit’ because it is this line from where the sum of positive and
negative deviation is Zero and sum of the square of deviation is least,

i.e., ∑(𝑌 − 𝑌𝑐 ) = 0 and ∑(𝑌 − 𝑌𝑐)2 is least.

(iii) It enables to compute the trend values for the whole time period.

(iv) The trend equation obtained by using least square method can be used to estimate or predict
the values of the variable for any given time period‘t’ in future and the predicted values are
reliable.

Demerits:

(i) This method is time consuming as the tedious calculations are involved under this method.

(ii) All the calculation needs to be re-done in case of adding/changing of even a single
observation.

(iii) Future prediction made by this method is based on long term variations and completely
ignore the cyclical, seasonal and irregular fluctuations.
Illustration : Fit a straight line trend by the method of least square from the following data and
find the trend values.

Solution

We have n = 5, n is odd

Taking middle year i.e. 1960 as the origin, we gets

N= 5 , ∑x = 0, ∑𝑥 2 = 10, ∑y = 460 and ∑xy = 100

a= Σy/n = 460/5 = 92

b= Σxy/ Σ𝑥 2 = 100/10 = 10

The equation of the straight line trend is Yc= a+ bx i.e Yc = 92+ 10 x

For the year 1958, x= -2

⇒ Yc (1958) = 92 + 10(−2) = 92 − 20 = 72

For the year 1959, x= -1

⇒ Yc (1959) = 92 + 10(−1) = 92 − 10 = 82

For the year 1960, x= 0

⇒ Yc (1960) = 92 + 10(0) = 92 − 0 = 92

For the year 1961, x= 1


⇒ Yc (1961) = 92 + 10(1) = 92 + 10 = 102

For the year 1962, x= 2

⇒ Yc (1962) = 92 + 10(2) = 92 + 20

Thus we have,

Illustration. The sales of a commodity (in ‘000 of Rs.) are given below:

(i) Using the method of least squares fit a straight line trend equation to the data.

(ii) What is the average annual change in the sales?

(iii) Obtain the trend value for the year 2014-2020 and show that the sum of difference between
actual and trend value is equal to zero.

(iv) What are the expected sales for the year 2025.

Solution:

In the given problem n= No. of year covered = 7 (odd). By taking 2017 (i.e. the middle year) as
origin and X unit as one year, we get the following:

FITTING STRAIGHT LINE TREND


The equation of the straight line trend is Yc= a + bX

Since ∑X = 0, the value of a and b can be obtained as follows:

a= ∑Y/n = 616/7=88

b = ∑XY/∑𝑥 2 =70/28 = 2.5

(i) Hence the equation of the straight line trend is: Yc= 88 + 2.5X with origin :

2017; X units: one year and Y units : Annual sales (in ‘000 of Rs.).

ii) The average annual change in the sales = b = 2.5 X 1000 = Rs. 2,500

(iii) The trend value for the year 2014-2020 are obtained by substituting X - -3, -2, -1, 0, 1, 2, 3
in straight line trend equation. These have been shown in the second last column of the above
table. The last column shows that the sum of difference between actual and trend value is equal
to zero.

(iv) For 2025, X will be 8

𝑌2025 = 88 + 2.5 (8) = 108

Thus the expected sales for the year 2025 are Rs. 1, 08,000.

Illustration: The decision making body of a fertilizer firm producing fertilizer wants to predict
future sales trend for the year 2006 and 2008 based on the analyses of its past sales pattern. The
sales of the firm for the last 7 years, for this purpose are given below:
Solution: To find the straight line equation ( Yc= a + bx) for the given time series data, we have
to substitute the values of already arrived expression, that is:
∑𝒚 ∑ 𝒙𝒚
𝒂= and 𝒃 =
𝑵 𝒙𝟐

In order to make the total of x = ‘zero’, we must take median year (i.e. 2001) as origin. Study the
following table carefully to understand the procedure for fitting the straight line.

∑𝒚 ∑ 𝒙𝒚
𝒂= = 609/7= 87 and 𝒃 = = 117/28= 4.18
𝑵 𝒙𝟐

Thus, the straight line trend equation is: Yc = 87 + 4.18x

From the above equation, we can also find the monthly increase in sales as follows:

4.180/12= 348.33 tons

The reason for this is that the trend values increased by a constant amount ‘b’ every year. Hence
the annual increase in sales in 4:18 thousand tons.

Trend values are to be obtained as follow:

𝑌1998 = 87+4.18 (–3) = 74.5

𝑌1999 = 87+4.18 (–2) = 78.6 and so on…


Predicting with decomposed components of the time series: The management wants to
estimate fertilizer sales for the years 2006 and 2008.

Estimation of sales for 2006, ‘x’ would be 5 (because for 2004 ‘x’ was 3)

𝑌2006 = 87 + 4.18 (5) = 1.7.9 thousand tonnes

Estimation of sales for 2008, ‘x’ would be 7.

𝑌2008 = 87 + 4.18 (7) = 116.3 thousand tonnes

You might also like