DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith...

52
DECISION MODELING WITH DECISION MODELING WITH MICROSOFT EXCEL MICROSOFT EXCEL Chapter 13 Chapter 13 Copyright 2001 Copyright 2001 Prentice Hall Publishers and Prentice Hall Publishers and Ardith E. Baker Ardith E. Baker Part 1 Part 1

Transcript of DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith...

Page 1: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

DECISION MODELING WITH DECISION MODELING WITH MICROSOFT EXCELMICROSOFT EXCEL

Chapter 13Chapter 13Chapter 13Chapter 13

Copyright 2001Copyright 2001Prentice Hall Publishers and Prentice Hall Publishers and

Ardith E. BakerArdith E. Baker

Part 1Part 1

Page 2: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Many important decisions made by Many important decisions made by individuals and organizations crucially individuals and organizations crucially depend on an assessment of the_________.depend on an assessment of the_________.

There are a few “____” sayings that There are a few “____” sayings that illustrate the promise and frustration of illustrate the promise and frustration of forecasting:forecasting:““It is difficult to_________, especially inIt is difficult to_________, especially in

regards to the future.” regards to the future.”

““It isn’t difficult to forecast, just to It isn’t difficult to forecast, just to forecastforecast___________.”___________.”““_______, if tortured enough, will confess _______, if tortured enough, will confess toto just about anything.” just about anything.”

Page 3: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Forecasting is playing an increasingly Forecasting is playing an increasingly important role in the_______________.important role in the_______________.

Economic forecasts__________Economic forecasts__________Government policies and business Government policies and business decisionsdecisionsInsurance companies’ Insurance companies’ ___________decisions in mortgages and ___________decisions in mortgages and bondsbondsService industries’ (such as airlines, Service industries’ (such as airlines, hotels, rental cars, cruise lines, etc.) hotels, rental cars, cruise lines, etc.) forecasts of _______as input for revenue forecasts of _______as input for revenue managementmanagement

There is clearly a steady __________in the use There is clearly a steady __________in the use of quantitative forecasting models at many of quantitative forecasting models at many levels in industry and government.levels in industry and government.

The many types of forecasting models will The many types of forecasting models will be distributed into two major techniques: be distributed into two major techniques:

___________and_______________________and____________

Page 4: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

____________forecasting models possess two ____________forecasting models possess two important and attractive features:important and attractive features:

1.1. They are expressed in mathematical They are expressed in mathematical ________. Thus, they establish an ________. Thus, they establish an unambiguous record of how the unambiguous record of how the forecast is made.forecast is made.

2.2. With the use of _______________and With the use of _______________and computers, quantitative models can computers, quantitative models can be based on an amazing quantity of be based on an amazing quantity of data.data.Two types of quantitative forecasting Two types of quantitative forecasting

models that will be discussed in the next models that will be discussed in the next two sections are:two sections are:________models and _________models________models and _________models

Page 5: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

In a _______In a _______forecastingforecasting model, the forecast model, the forecast for the quantity of interest “rides for the quantity of interest “rides piggyback” on another quantity or set of piggyback” on another quantity or set of quantities.quantities.In other words, our ________of the value of In other words, our ________of the value of one variable (or perhaps several variables) one variable (or perhaps several variables) enables us to forecast the value of enables us to forecast the value of another___________.another___________.In this model, letIn this model, let

yy denote the _________of some variable denote the _________of some variable of interest andof interest and

yy denote a predicted or _________value denote a predicted or _________value for that variable.for that variable.

Page 6: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Then, in a causal model, Then, in a causal model,

wherewhere

ff is a forecasting________, or function, is a forecasting________, or function, andandxx11, , xx2 2 , … , … xxi i , is a set of variables, is a set of variables

yy = = ff((xx11, , xx22, … , … xxnn))^̂

In this representation, the In this representation, the xx variables are variables are often called _________often called _________variablesvariables, whereas , whereas yy is is the the dependent dependent or __________or __________variablevariable..

We either _______the independent variables We either _______the independent variables in advance or can forecast them more easily in advance or can forecast them more easily than than yy. .

Then the independent variables will be used Then the independent variables will be used in the forecasting model to forecast the in the forecasting model to forecast the __________ variable.__________ variable.

Page 7: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Companies often find by looking at past Companies often find by looking at past __________that their monthly sales are __________that their monthly sales are directly related to the monthly______, and directly related to the monthly______, and thus figure that a good forecast could be thus figure that a good forecast could be made using next month’s GDP figure.made using next month’s GDP figure.

The only problem is that this quantity is not The only problem is that this quantity is not _______, or it may just be a forecast and thus _______, or it may just be a forecast and thus not a truly independent___________.not a truly independent___________.

To use a causal forecasting model, requires To use a causal forecasting model, requires two conditions:two conditions:

1.1. There must be a ___________between There must be a ___________between values of the independent and values of the independent and dependent variables such that the dependent variables such that the former provides ____________about the former provides ____________about the latter.latter.

Page 8: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

2.2. The _______for the independent The _______for the independent variables must be known and variables must be known and available to the forecaster at the available to the forecaster at the ____the forecast is made.____the forecast is made.

Simply because there is a mathematical Simply because there is a mathematical relationship does not ___________that there is relationship does not ___________that there is really cause and effect. really cause and effect.

One commonly used approach in creating a One commonly used approach in creating a causal forecasting model is causal forecasting model is called_____________.called_____________.

Consider an oil company that is planning to Consider an oil company that is planning to expand its _________of modern self-service expand its _________of modern self-service gasoline stations. gasoline stations.

CURVE FITTING: CURVE FITTING: AN OIL COMPANY EXPANSIONAN OIL COMPANY EXPANSION

Page 9: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

The company plans to use The company plans to use __________(measured in the average number __________(measured in the average number of cars per hour) to forecast of cars per hour) to forecast ______(measured in average dollar sales per ______(measured in average dollar sales per hour).hour).The firm has had five stations in operation The firm has had five stations in operation for more than a year and has used for more than a year and has used _________data to calculate the following _________data to calculate the following averages:averages:

Page 10: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

The averages are plotted in a scatter The averages are plotted in a scatter diagram.diagram.

$-

$50.00

$100.00

$150.00

$200.00

$250.00

$300.00

0 50 100 150 200 250

Cars/hour

Sal

es

/ho

ur

($)

Page 11: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Now, these data will be used to construct a Now, these data will be used to construct a _________that will be used to forecast sales at _________that will be used to forecast sales at any proposed location by measuring the any proposed location by measuring the traffic flow at that ________and plugging its traffic flow at that ________and plugging its value into the constructed function.value into the constructed function.

Least Squares FitsLeast Squares Fits The method of The method of __________is a formal procedure for curve __________is a formal procedure for curve fitting. It is a two-step process.fitting. It is a two-step process.

1.1. Select a specific functional form (e.g., Select a specific functional form (e.g., a ___________or quadratic curve).a ___________or quadratic curve).

2.2. Within the set of functions specified Within the set of functions specified in step 1, choose the specific function in step 1, choose the specific function that __________the sum of the squared that __________the sum of the squared deviations between the data points deviations between the data points and the function___________.and the function___________.

Page 12: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

To demonstrate the process, consider the To demonstrate the process, consider the sales-traffic flow example.sales-traffic flow example.

1.1. Assume a _______line; that is, functions Assume a _______line; that is, functions of the form of the form y = a + bxy = a + bx..

2.2. Draw the line in the ____________and Draw the line in the ____________and indicate the __________between indicate the __________between observed points and the function as observed points and the function as ddi i ..

dd11 = = yy11 – [a +b – [a +bxx11] = 220 – [a + 150b] ] = 220 – [a + 150b] For example,For example,

wherewhereyy1 1 = actual sales/hr at location 1= actual sales/hr at location 1xx11 = actual traffic flow at location 1 = actual traffic flow at location 1aa = = yy-axis intercept for the function-axis intercept for the functionbb = slope for the function = slope for the function

Page 13: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

The value The value dd1122 is one measure of __________the is one measure of __________the

value of the function value of the function [a +b[a +bxx11] ] is to the is to the ________ value, ________ value, yy11; that is it indicates how ; that is it indicates how well the function fits at this one point.well the function fits at this one point.

$-

$50.00

$100.00

$150.00

$200.00

$250.00

$300.00

0 50 100 150 200 250

Cars/hour

Sal

es

/ho

ur

($)

dd22

dd55

dd44

dd11

dd33

y y == a a + + bxbx

yy

xx

Page 14: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

One measure of how well the function fits One measure of how well the function fits overall is the sum of the __________________:overall is the sum of the __________________:

ddii22

i=1i=1

55

Consider a ________model with Consider a ________model with nn as opposed as opposed to five____________. Since each to five____________. Since each ddi i = = yyii – (a – (a +b+bxxii)), the sum of the squared deviations , the sum of the squared deviations can be written as:can be written as:

i=1i=1

nn

((yyii – [a +b – [a +bxxii])])22

Using the method of__________, select Using the method of__________, select aa and and bb so as to minimize the sum in the equation so as to minimize the sum in the equation above.above.

Page 15: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Now, take the __________derivative of the Now, take the __________derivative of the sum with respect to sum with respect to aa and set the resulting and set the resulting expression equal to______.expression equal to______.

i=1i=1

nn

-2(-2(yyii – [a +b – [a +bxxii]) = 0]) = 0

A second __________is derived by following A second __________is derived by following the same procedure with the same procedure with bb..

i=1i=1

nn

-2-2xxii ( (yyii – [a +b – [a +bxxii]) = 0]) = 0

Recall that the values for Recall that the values for xxii and and yyii are the are the ______________, and our goal is to find the ______________, and our goal is to find the values of values of aa and and bb that satisfy these two that satisfy these two equations. equations.

Page 16: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

The solution is:The solution is:

xxii

i=1i=1

nn

xxiiyyi i --b =b =

11nn

i=1i=1

nn

xxii i=1i=1

nn

yyii

i=1i=1

nn

xxii22 --

11nn

i=1i=1

nn22

aa == 11nn

i=1i=1

nn

yyii - b- b 11nn

i=1i=1

nn

xxii

The next step is to determine the values The next step is to determine the values for:for:

i=1i=1

nn

xxii22

i=1i=1

nn

yyiii=1i=1

nn

xxii i=1i=1

nn

xxiiyyii

Note that these _______depend only on Note that these _______depend only on observed data and can be found with simple observed data and can be found with simple arithmetic ___________or automatically using arithmetic ___________or automatically using Excel’s predefined___________.Excel’s predefined___________.

Page 17: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Using Excel, click on Using Excel, click on Tools – Data Analysis …Tools – Data Analysis …

In the resulting In the resulting dialog, choose dialog, choose

RegressionRegression..

Page 18: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

In the __________dialog, enter the In the __________dialog, enter the YY-range -range and and XX-range.-range.

Choose Choose to place to place the the _______in _______in a new a new worksheeworksheet called t called ResultsResults

Select ___________and Select ___________and Normal Probability Normal Probability PlotsPlots to be created along with the output. to be created along with the output.

Page 19: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Click Click OKOK to produce the following results: to produce the following results:

Note that Note that a a ((InterceptIntercept) and ) and bb ( (X Variable 1X Variable 1) ) are reported as are reported as 57.10457.104 and and 0.929970.92997, , respectively.respectively.

Page 20: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

To add the resulting ____________line, first To add the resulting ____________line, first click on the worksheet click on the worksheet Chart 1Chart 1 which which contains the original_____________.contains the original_____________.

Next, click on the ____________so that they Next, click on the ____________so that they are highlighted and then choose are highlighted and then choose Add Add Trendline …Trendline … from the from the ChartChart pull-down menu. pull-down menu.

Page 21: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Choose Choose Linear TrendLinear Trend in the resulting dialog in the resulting dialog and click and click OKOK..

Page 22: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

A linear trend is fit to the data:A linear trend is fit to the data:

$-

$50.00

$100.00

$150.00

$200.00

$250.00

$300.00

0 50 100 150 200 250

Cars/hour

Sal

es

/ho

ur

($)

Series1

Linear (Series1)

Page 23: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

One of the other __________output values that One of the other __________output values that is given in Excel is: is given in Excel is: R Square = 69.4%R Square = 69.4%

This is a “_________” measure which This is a “_________” measure which represents the represents the RR22 statistic discussed in statistic discussed in introductory statistics classes.introductory statistics classes.

RR22 ranges in value from __________and gives ranges in value from __________and gives an indication of how much of the total an indication of how much of the total ________in ________in YY from its mean is explained by from its mean is explained by the new trend line.the new trend line.In fact, there are three different sums of In fact, there are three different sums of errors:errors:

TSSTSS (________Sum of Squares) (________Sum of Squares)

ESSESS (________Sum of Squares) (________Sum of Squares)

RSSRSS (________Sum of Squares) (________Sum of Squares)

Page 24: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

The basic relationship between them is:The basic relationship between them is:

TSS = ESS + RSSTSS = ESS + RSS

They are defined as follows:They are defined as follows:

TSS TSS ==

i=1i=1

nn

((YYii – – Y Y ))22––

ESS ESS ==

i=1i=1

nn

((YYii – – YYii ))22^̂

i=1i=1

nn

((YYii – – Y Y ))22^̂ ––RSS RSS ==

Essentially, the ____is the amount of Essentially, the ____is the amount of variation that can’t be explained by variation that can’t be explained by the___________.the___________.The ____quantity is effectively the amount of The ____quantity is effectively the amount of the ________, total variation (the ________, total variation (TSSTSS) that could ) that could be removed using the regression line.be removed using the regression line.

Page 25: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

If the regression line fits________, then If the regression line fits________, then ESS = ESS = 00 and and RSS = TSSRSS = TSS, resulting in , resulting in RR22 = 1= 1..

RR22 = =RSSRSSTSSTSS

RR22 is defined as: is defined as:

In this example, In this example, RR22 = .694 = .694 which means that which means that approximately approximately 70%70% of the variation in the of the variation in the YY values is explained by the one ____________ values is explained by the one ____________ variable (variable (XX), cars per hour.), cars per hour.

Page 26: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Now, returning to the original question: Now, returning to the original question: Should we build a station at Buffalo Grove Should we build a station at Buffalo Grove where traffic is 183 cars/hour?where traffic is 183 cars/hour?

The best guess at what the corresponding The best guess at what the corresponding _____ volume would be is found by placing _____ volume would be is found by placing this this XX value into the new value into the new ____________equation:____________equation:

Sales/hour = 57.104 + 0.92997 * (183 Sales/hour = 57.104 + 0.92997 * (183 cars/hour)cars/hour)

However, it would be nice to be able to However, it would be nice to be able to state a _____confidence interval around this state a _____confidence interval around this best guess. best guess.

yy = a + b * = a + b * xx^̂

= $227.29= $227.29

Page 27: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Excel reports that the Excel reports that the ______________(______________(SSee) is ) is 44.1844.18. . This quantity This quantity represents the represents the amount of ______in the amount of ______in the actual data around actual data around the regression line.the regression line.

We can get the information to do this from We can get the information to do this from Excel’s Excel’s Summary OutputSummary Output..

The formula for The formula for SSee is: is:

SSee = =i=1i=1

nn

((YYii – – YYii ))22^̂

nn – – kk - -11

Where Where nn is the is the number of data number of data points (e.g., points (e.g., 55) and ) and kk is the number of is the number of ___________variables ___________variables (e.g., (e.g., 11).).

Page 28: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

This equation is __________to:This equation is __________to:nn – – kk - -11

ESSESS

Once we know Once we know SSee and based on the ______ and based on the ______ distribution, we can state that distribution, we can state that

• We have We have 68%68% confidence that the confidence that the _____ value of sales/hour is within _____ value of sales/hour is within ++ 1 1 SSee of the predicted value ( of the predicted value ($277.29$277.29).).

• We have We have 95%95% confidence that the confidence that the actual value of _____/hour is within actual value of _____/hour is within ++ 22 SSee of the predicted value of the predicted value (($277.29$277.29). ).

[[277.29 – 2(44.18)277.29 – 2(44.18);; 227.29 + 2(44.18) 227.29 + 2(44.18)]]

[[$138.93$138.93;; $315.65 $315.65]]

The The 95%95% ___________interval is: ___________interval is:

Page 29: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Another value of interest in the Another value of interest in the SummarySummary report is the ____________for the report is the ____________for the XX variable variable and its associated values.and its associated values.

The The tt-statistic is -statistic is 2.612.61 and the ________is and the ________is 0.07980.0798. . A A PP-value less than -value less than 0.050.05 represents that we represents that we have at least have at least 95%95% confidence that the confidence that the ____parameter (____parameter (bb) is statistically ) is statistically significantly than significantly than 00 (zero). (zero). A slope of __results in a flat trend ______and A slope of __results in a flat trend ______and indicates no relationship between indicates no relationship between YY and and XX..

The The 95%95% confidence limit for confidence limit for bb is [ is [-0.205-0.205;; 2.0642.064]]Thus, we can’t _________the possibility that Thus, we can’t _________the possibility that the true value of the true value of bb might be might be 00..

Page 30: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Also given in the Also given in the SummarySummary report is the report is the _____________. Since there is only ____ _____________. Since there is only ____ independent variable, the independent variable, the F F –significance is –significance is identical to the identical to the PP-value for the -value for the t-t-statistic.statistic.

In the case of more than one In the case of more than one XX variable, the variable, the FF –significance tests the ___________that all –significance tests the ___________that all the the XX variable parameters as a group are variable parameters as a group are statistically significantly different than zero.statistically significantly different than zero.

Page 31: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Concerning multiple regression________, as Concerning multiple regression________, as you add other you add other XX variables, the variables, the RR22 statistic statistic will always _______, meaning the will always _______, meaning the RSSRSS has has increased.increased. In this case, the _________ In this case, the _________

RR22 statistic is a reliable statistic is a reliable __________of the true __________of the true

goodness of fit because goodness of fit because it compensates for the it compensates for the

reduction in the ____due reduction in the ____due to the addition of more to the addition of more independent variables.independent variables.

Thus, it may report a _________adjusted Thus, it may report a _________adjusted RR22 value even though value even though RR22 has increased, unless has increased, unless the improvement in ____is more than the improvement in ____is more than compensated for by the __________of the new compensated for by the __________of the new independent variables.independent variables.

Page 32: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Fitting a Quadratic FunctionFitting a Quadratic Function The method of The method of least ________can be used with any number least ________can be used with any number of independent variables and with any of independent variables and with any _________ form (not just linear). _________ form (not just linear). Suppose that we wish to fit a Suppose that we wish to fit a _________function of the form _________function of the form

yy = a = a00 + a + a11xx + a + a22xx22

to the previous data with the method of to the previous data with the method of least squares. least squares. The goal is to select The goal is to select aa0 0 ,, a a1 1 ,, and and aa22 in order in order to __________the sum of squared deviations, to __________the sum of squared deviations, which is nowwhich is now

i=1i=1

55

((yyi i – [a– [a00 + a + a11xxii + a + a22xxii22 ])])22

Page 33: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Proceed by setting the partial Proceed by setting the partial ____________with respect to ____________with respect to aa0 0 ,, a a1 1 ,, and and aa22 equal to______. This gives the equationsequal to______. This gives the equations

5a5a00 + ( + (xxii)a)a11 + ( + (xxii2 2 )a)a22 = = yyii

((xxii)a)a00 + ( + (xxii22)a)a11 + ( + (xxii

33)a)a22 = = xxiiyyii

((xxii22)a)a00 + ( + (xxii

33)a)a11 + ( + (xxii44)a)a22 = = xxii

22yyii

This is a simple set of three linear equations This is a simple set of three linear equations in three__________.in three__________.

Thus, the general name for this least Thus, the general name for this least squares curve fitting is “___________________.” squares curve fitting is “___________________.”

The term _________comes from the fact that The term _________comes from the fact that simultaneous linear equations are being simultaneous linear equations are being solved.solved.

Page 34: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Solver will be used to find the coefficients in Solver will be used to find the coefficients in Excel. Consider the following worksheet:Excel. Consider the following worksheet:

Page 35: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Now, to find the ____________values for the Now, to find the ____________values for the parameters (parameters (aa0 0 ,, a a1 1 ,, and and aa22) using________, ) using________, first click on first click on Tools – SolverTools – Solver..

Page 36: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

In the resulting In the resulting Solver Parameter Solver Parameter dialog, dialog, specify the following settings:specify the following settings:

Click Click SolveSolve to solve the____________, to solve the____________, nonlinear optimization model. nonlinear optimization model.

In this model, the objective function is to In this model, the objective function is to minimize the sum of_______________.minimize the sum of_______________.

Page 37: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Here are the Solver results.Here are the Solver results.

The parameter values are:The parameter values are:

This formula calculates the sum of squared This formula calculates the sum of squared errors directly. errors directly.

Page 38: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Use Excel’s Use Excel’s Chart WizardChart Wizard to plot the to plot the _______data and the resulting _______data and the resulting ___________function.___________function.First, highlight the original range of data, First, highlight the original range of data, then click on the ______________button.then click on the ______________button.

Page 39: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Use Excel’s Use Excel’s Chart WizardChart Wizard to plot the original to plot the original data as a __________and specify a quadratic data as a __________and specify a quadratic function via the function via the Chart – Add Trendline …Chart – Add Trendline … option.option.

$-

$50.00

$100.00

$150.00

$200.00

$250.00

$300.00

0 50 100 150 200 250

Cars/hour

Sal

es

/ho

ur

Series1

Poly. (Series1)

Page 40: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Comparing the Linear and Quadratic FitsComparing the Linear and Quadratic Fits In In the method of least squares, the _____of the the method of least squares, the _____of the squared deviations was selected as the squared deviations was selected as the measure of “______________.”measure of “______________.”

Thus, the linear and quadratic fits can be Thus, the linear and quadratic fits can be compared with this___________.compared with this___________.

In order to make this comparison, go back In order to make this comparison, go back to the linear regression “________” to the linear regression “________” spreadsheet and make the corresponding spreadsheet and make the corresponding calculation in the original “______” calculation in the original “______” spreadsheet.spreadsheet.

Page 41: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Note that the sum of the squared deviations Note that the sum of the squared deviations for the ________function is indeed smaller for the ________function is indeed smaller than that for the ______function (i.e., than that for the ______function (i.e., 49544954 < < 5854.75854.7).).Indeed, the quadratic gives roughly a 15% Indeed, the quadratic gives roughly a 15% __________in the sum of squared deviations. __________in the sum of squared deviations.

It follows then: the best quadratic function It follows then: the best quadratic function must be _______as good as the best linear must be _______as good as the best linear function.function.

A linear function is a special type of ________ A linear function is a special type of ________ function in which function in which aa22 = 0= 0..

Page 42: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

If a quadratic function is at least as good as If a quadratic function is at least as good as a linear function, why not choose a more a linear function, why not choose a more ________ form, thereby getting an even ________ form, thereby getting an even better_____?better_____?

WHICH CURVE TO FIT?WHICH CURVE TO FIT?

In practice, _______of the form (with only a In practice, _______of the form (with only a single independent variable for illustrative single independent variable for illustrative purposes) are often suggested:purposes) are often suggested:

yy = a = a00 + a + a11xx + a + a22xx2 2 + … + a+ … + annxxnn

Such a function is called a _________Such a function is called a _________of degree of degree nn, and it represents a broad and flexible , and it represents a broad and flexible class of functions.class of functions.

n n = 2= 2quadraticquadraticn n = 3= 3 cubiccubicn n = 4= 4 ______________……

Page 43: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

One must proceed with __________when One must proceed with __________when fitting data with a ___________function.fitting data with a ___________function.

For example, it is possible to find a (For example, it is possible to find a (kk – 1 – 1)-)-degree polynomial that will _________fit degree polynomial that will _________fit kk data points.data points.To be more specific, suppose we have seven To be more specific, suppose we have seven _________observations, denoted _________observations, denoted

((xxi i , , yyii), ), ii = 1, 2, …, 7 = 1, 2, …, 7

It is possible to find a ____________polynomialIt is possible to find a ____________polynomialyy = a = a00 + a + a11xx + a + a22xx2 2 + … + a+ … + a66xx66

that exactly passes through each of these that exactly passes through each of these seven data points.seven data points.

Page 44: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

A perfect fit gives ______for the sum of A perfect fit gives ______for the sum of squared deviations.squared deviations.

However, However, this is this is

________, ________, for it does for it does not imply not imply

much much about the about the

_________ _________ value of value of

the model the model for use in for use in

future future forecastinforecastin

g. g.

Page 45: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Despite the ________of the polynomial Despite the ________of the polynomial function, the forecast is very_______. The function, the forecast is very_______. The linear fit might provide more linear fit might provide more __________forecasts.__________forecasts. Also, note Also, note

that the that the polynomial polynomial

fit has fit has __________ex__________extrapolation trapolation properties properties

(i.e., the (i.e., the polynomial polynomial “_________” “_________”

at its at its extremes).extremes).

Page 46: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

One way of finding which fit is truly One way of finding which fit is truly “better” is to use a different standard “better” is to use a different standard of_____________, the “mean squared error” or of_____________, the “mean squared error” or MSE.MSE.

MSE MSE ==

sum of squared sum of squared errorserrors(# of points – # of (# of points – # of

parameters)parameters)For the___________, the number of parameters For the___________, the number of parameters estimated is 2 (estimated is 2 (aa, , bb))

MSE MSE ==

58558544(5-2)(5-2)

= 1951.3= 1951.3

MSE MSE ==

49549544(5-3)(5-3)

= 2477.0= 2477.0

For the quadratic fitFor the quadratic fit

Page 47: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

So, the MSE gets ______in this case even So, the MSE gets ______in this case even though the total sum of squares will always though the total sum of squares will always be less or the same for a ___________fit.be less or the same for a ___________fit.

When there is a_________, both the total sum When there is a_________, both the total sum of squares and the MSE will be_____. of squares and the MSE will be_____.

Because of this, most forecasting programs Because of this, most forecasting programs will fit only up through a _____polynomial, will fit only up through a _____polynomial, since higher degrees don’t reflect the since higher degrees don’t reflect the general trend of ______data.general trend of ______data.

Page 48: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

What is a Good Fit?What is a Good Fit? A good historical fit A good historical fit may have poor _______power. So what is a may have poor _______power. So what is a good fit?good fit?It depends on whether one has some idea It depends on whether one has some idea about the _________real-world process that about the _________real-world process that relates the relates the yy’s and ’s and xx’s.’s.

To be an __________forecasting device, the To be an __________forecasting device, the forecasting function must to some extent forecasting function must to some extent capture important ________of that process.capture important ________of that process.

The more one knows, the _______one can do.The more one knows, the _______one can do.

However, knowledge of the underlying However, knowledge of the underlying process is typically phrased in__________ process is typically phrased in__________ language.language.For example, linear curve fitting, in the For example, linear curve fitting, in the statistical context, is called______________. statistical context, is called______________.

Page 49: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

If the statistical _____________about the linear If the statistical _____________about the linear regression model are precisely satisfied regression model are precisely satisfied (e.g., errors are _________distributed around (e.g., errors are _________distributed around the regression line), then in a precise and the regression line), then in a precise and well-defined sense, statisticians can prove well-defined sense, statisticians can prove that the linear fit is the “______possible fit.”that the linear fit is the “______possible fit.”

In the real world one can never be In the real world one can never be completely certain about the completely certain about the ____________process.____________process.The question then becomes: How much The question then becomes: How much ___________can we have that the underlying ___________can we have that the underlying process is one that satisfies a particular set process is one that satisfies a particular set of statistical____________?of statistical____________?

Fortunately, statistical analysis can reveal Fortunately, statistical analysis can reveal how well the _________data do indeed satisfy how well the _________data do indeed satisfy those assumptions.those assumptions.

Page 50: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

And if it does not satisfy the assumptions, And if it does not satisfy the assumptions, then try a different________.then try a different________.

Remember, there is an underlying real-Remember, there is an underlying real-world _________and the model is a selective world _________and the model is a selective ___________________of that problem.___________________of that problem.

How good is that model? Ideally, to test the How good is that model? Ideally, to test the goodness of a model, one would like to have goodness of a model, one would like to have considerable ____________with its use. considerable ____________with its use.

If, in repeated use, it is observed that the If, in repeated use, it is observed that the model performs well, then our confidence model performs well, then our confidence is________. However, what confidence can we is________. However, what confidence can we have at the outset, without experience?have at the outset, without experience?

Page 51: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

Validating ModelsValidating Models One_________, is to ask One_________, is to ask the question: Suppose the model had been the question: Suppose the model had been used to make past decisions; how well used to make past decisions; how well would the firm have fared?would the firm have fared?

This approach “creates” experience by This approach “creates” experience by ________ the past.________ the past.

This is often referred to as _________of the This is often referred to as _________of the model.model.

Typically, one uses only a ______of the Typically, one uses only a ______of the historical data to create the model – for historical data to create the model – for example, to fit a polynomial of a specified example, to fit a polynomial of a specified degree. degree. One can then use the remaining _____to see One can then use the remaining _____to see how well the model would have performed.how well the model would have performed.

Page 52: DECISION MODELING WITH MICROSOFT EXCEL Chapter 13 Copyright 2001 Prentice Hall Publishers and Ardith E. Baker Part 1.

End of Part 1End of Part 1Please continue to Part 2Please continue to Part 2