You are on page 1of 19

Business Analytics 2nd Semester SY.

2021-2022

Spreadsheet Models
Spreadsheet models - mathematical and logic-based models
- provide easy-to-use, sophisticated mathematical and logical functions, allowing for easy
instantaneous recalculation for a change in model input
- often referred to as what-if models

BUILDING GOOD SPREADSHEET MODELS


The total cost of manufacturing a product can usually be defined as the sum of two costs: fixed
cost and variable cost.

Fixed cost – is the portion of the total cost that does not depend on the production quantity;
this cost remains the same no matter how much is produced.
Variable cost – is the portion of the total cost that is dependent on and varies with the
production quantity.

Illustrative Example:

MmC Plastics produces a line of cell phone covers. MmC’s best-selling cover is its Viper model, a slim but very
durable black and gray plastic cover.

The annual fixed cost for the Viper cover is Php 234,000.00. This fixed cost includes management time,
advertising, and other costs that are incurred regardless of the number of units eventually produced. In
addition, the total variable cost, including labor and material costs, is Php 20.00 for each unit produced.

MmC is considering outsourcing the production of some products for next year, including the Viper. MmC has
a bid from an outside firm to produce the Viper for Php 35.00 per unit. Although it is more expensive per unit
to outsource the Viper (Php 35.00 versus Php 20.00), the fixed cost can be avoided if MmC purchases rather
than manufactures the product.

The exact demand for Viper for next year is not yet known. MmC would like to compare the costs of
manufacturing the Viper in-house to those of outsourcing its production to another firm, and management
would like to do that for various production quantities.

Many manufacturers face this type of decision, which is known as a make-versus-buy


decision.
1
Business Analytics 2nd Semester SY. 2021-2022

Influence Diagrams
It is often useful to begin the modeling process with a conceptual model that shows the
relationships between the various parts of the problem being modeled. The conceptual model
helps in organizing the data requirements and provides a road map for eventually constructing
a mathematical model. A conceptual model also provides a clear way to communicate the
model to others.

Influence Diagram - a visual representation that shows which entities influence others in a
model. Parts of the model are represented by circular or oval symbols called nodes, and
arrows connecting the nodes show influence.

Figure 5.1 shows an influence diagram for MmC’s total cost of production for the Viper.

Figure 5.1 An Influence Diagram for MmC’s Manufacturing Cost

Total manufacturing cost depends


on fixed cost and variable cost,
which in turn, depends on the
variable cost per unit and the
quantity required.

2
Business Analytics 2nd Semester SY. 2021-2022

Figure 5.2
An Influence
Diagram for
Comparing
Manufacturing
Versus
Outsourcing Cost
for MmC Plastics

Building a Mathematical Model


The task now is to use the influence diagram to build a mathematical model.
Let us first consider the cost of manufacturing the required units of the Viper. As the
influence diagram shows, this cost is a function of the fixed cost, the variable cost per unit, and
the quantity required. In general, it is best to define notation for every node in the influence
diagram.
Let us define the following:
q = quantity (number of units) required
FC = the fixed cost of manufacturing
VC = the per-unit variable cost of manufacturing
TMC(q) = total cost to manufacture q units

The cost-volume model for producing q units of the Viper can then be written as follows:

TMC(q) = FC + (VC x q)

3
Business Analytics 2nd Semester SY. 2021-2022

Equation 5.1

For the Viper, FC = Php 234,000.00 and VC = Php 20.00 , so that equation (5.1) becomes
TMC(q) =Php 234,000.00 + 20q

Once a quantity required (q) is established, equation (5.1), now populated with the data for
the Viper, can be used to compute the total manufacturing cost .

For example, the decision to produce q = 10,000 units would result in a total cost of:
TMC(10,000) = 234,000 + 20(10,000)
= 434,000.00

Similarly, a mathematical model for purchasing q units is as follows.


Let P = the per unit purchase cost, and
TPC(q) = the total cost to outsource or purchase q units

Equation 5.2

TPC(q) = Pq

For the Viper, since P = Php 35.00, equation (7.2) becomes


TPC(q) = Php 35.00q

Thus, the total cost to outsource 10,000 units of the Viper is


TPC(10,000) = 35(10,000)
Php 35,000.00

We can now state mathematically the savings associated with outsourcing.

Let S(q) = the savings due to outsourcing, that is, the difference between the total
cost of manufacturing q units and the total cost of buying q units.

4
Business Analytics 2nd Semester SY. 2021-2022

Equation 5.3

S(q) = TMC(q) - TPC(q)

Spreadsheet Design and Implementing the Model in a Spreadsheet


For the MmC Plastics problem, we have defined the following components
(corresponding
to the nodes of the influence diagram in Figure 5.2):

q = quantity (number of units) required


FC = the fixed cost of manufacturing
VC = the per-unit variable cost of manufacturing
TMC(q) = total cost to manufacture q units
P = the per-unit purchase cost
TPC(q) = the total cost to purchase q units
S(q) = the savings from outsourcing q units

• Several points are in order. Some of these components are a function of other
components (TMC, TPC, and S), and some are not (q, FC, VC, and P).

• TMC, TPC, and S will be formulas involving other cells in the spreadsheet model,
whereas q, FC, VC, and P will just be entries in the spreadsheet.

• The value we can control or choose is q.

• In our analysis, we seek the value of q, such that S(q) > 0; that is, the savings
associated with outsourcing is positive.

• The number of Vipers to make or buy for next year is really a decision MmC gets to
make. So, we will treat q somewhat differently than we will FC, VC, and P in the
spreadsheet model, and we refer to the quantity q as a decision variable.

• FC, VC, and P, are measurable factors that define characteristics of the process we
are modelling and so are uncontrollable inputs to the model, which we refer to as
parameters of the model.

5
Business Analytics 2nd Semester SY. 2021-2022

Figure 5.3 MmC Plastics Make-Versus-Buy Spreadsheet Model

• In cell B9 of Figure 5.3, we have set the value of q to 10,000 units.


• The model shows that the cost to manufacture 10,000 units is Php 434,000.00, the
cost to purchase the 10,000 units is Php 350,000.00, and the savings from
outsourcing is at
Php 84,000.00
• We see that, at a quantity of 10,000 units, it is better to produce than to buy

• This is called a trial-and-error approach

The general principles of spreadsheet model design and construction are:


● Separate the parameters from the model
● Document the model, and use proper formatting and color as needed
● Use simple formulas

WHAT-IF ANALYSIS
DATA TABLES
An Excel Data Table quantifies the impact of changing the value of a specific input on
an output of interest. Excel can generate either one of the following:
a. one-way data table – summarizes a single input’s impact on the output, or
b. two-way data table – summarizes two inputs’ impact on the output

Let us consider how savings due to outsourcing changes as the quantity of Vipers
required changes. This should help us answer the question,

6
Business Analytics 2nd Semester SY. 2021-2022

“For which values of q is outsourcing more cost-effective?”

A one-way data table changing the value of quantity and reporting savings due to
outsourcing would be very useful.
We will use the previously developed MmC spreadsheet for this analysis.

• The first step in creating a one-way data table is to construct a sorted list of the values
you would like to consider for the input.
• Let us investigate the quantity q over a range from 0 to 300,000 in increments of 25,000
units. Figure 5.4 shows we have entered these data in cells D4 through D16, with a
column label in D3.
Figure 5.4 The Input for Constructing A One-Way Data Table For MmC Plastics

• This column of data is the set of values that Excel will use as inputs for q. Since the output
of interest is savings due to outsourcing (located in cell B12), we have entered the formula
=B12 in cell E3.
• In general, set the cell to the right of the label to the cell location of the output variable of
interest.
• Once the basic structure is in place, we invoke the Data Table tool using the following
steps:

7
Business Analytics 2nd Semester SY. 2021-2022

Step 1. Select cells D3:E16


Step 2. Click the DATA tab in the Ribbon
Step 3. Click What-If Analysis in the Data Tools group, and select Data Table
When the Data Table dialog box appears, enter B9 in the Column input
Step 4.
cell: box
Click OK

• As shown in Figure 5.5, the table will be populated with the value of savings due to
outsourcing for each value of quantity of Vipers in the table.
Figure 5.5 Results of One-Way Data Table for MmC Plastics

• Suppose that MmC has now received five different bids on the per-unit cost for outsourcing
the production of the Viper.

• Clearly, the lowest bid provides the greatest savings.


• However, the selection of the outsource firm—if MmC decides to outsource—will depend on
many factors, including reliability, quality, and on-time delivery.
So, it would be instructive to quantify the differences in savings for various quantities and bids.

• The five current bids are Php 28.90, Php 30.00, Php 31.30, Php 35.40, and Php 35.90.

• We may use the Excel Data Table to construct a two-way data table with quantity as a column
and the five bids as a row, as shown in Figure 5.6.

8
Business Analytics 2nd Semester SY. 2021-2022

Figure 7.6 The Input for Constructing A Two-Way Data Table for MmC Plastics

• In Figure 5.6, we have entered various quantities in cells D4 through D16, as in the
one-way table.
These correspond to cell B9 in our model.
• In cells E3 through I3, we have entered the bids.
These correspond to B6, the outsourcing cost per unit.
• In cell D3, above the column input values and to the left of the row input values, we
have entered the formula =B12, the location of the output of interest, in this case,
savings due to outsourcing.
• Once the table inputs have been entered into the spreadsheet, we perform the
following steps to construct the two-way Data Table.

Step 1. Select cells D3:I16


Step 2. Click the DATA tab in the Ribbon
Step 3. Click What-If Analysis in the Data Tools group, and select Data Table
When the Data Table dialog box appears,
Step 4.
ENTER B6 in the Row input cell: box
ENTER B9 in the Column input cell: box
Click OK

The results are shown in Figure 5.7.


Figure 5.7 Results ff Two-Way Data Table for MmC Plastics

9
Business Analytics 2nd Semester SY. 2021-2022

GOAL SEEK
Excel’s Goal Seek tool allows the user to determine the value of an input cell that will cause
the value of a related output cell to equal some specified value (the goal).

• In the case of MmC Plastics, suppose we want to know the value of the quantity of
Vipers where it becomes more cost effective to manufacture rather than outsource.
• For example, we see from the table in Figure 5.7 that, for a bid price of Php 28.90 and
some quantity between 25,000 units and 50,000 units, savings due to outsourcing
goes from positive to negative.
• Somewhere in this range of quantity, the savings due to outsourcing is zero, and that
is the point where MmC would be indifferent to manufacturing and outsourcing.
• We may use Goal Seek to find the quantity of Vipers that satisfies the goal of zero
savings due to outsourcing for a bid price of Php 28.90.
• The following steps describe how to use Goal Seek to find this point.

Step 1. Click the DATA tab in the Ribbon


Step 2. Click What-If Analysis in the Data Tools group, and select Goal Seek
When the Goal Seek dialog box appears (Figure 5:8):
Step 3.
Enter B12 in the Set cell: box
Enter 0 in the To value: box
Enter B9 in the By changing cell: box
Click OK
Step 4. When the Goal Seek Status dialog box appears, click OK

10
Business Analytics 2nd Semester SY. 2021-2022

Figure 7.8 Goal Seek Dialog Box for MmC Plastics

• The results from Goal Seek are shown in Figure 7.9.


• The savings due to outsourcing in cell B12 is zero, and the quantity in cell B9 has been
set by Goal Seek to 15,600.
• When the annual quantity required is 15,600, it costs Php 546,000 either to manufacture
the product or to purchase it.
• We have already seen that lower values of the quantity required favor outsourcing.
• Beyond the value of 15,600 units, it becomes cheaper to manufacture the product.

11
Business Analytics 2nd Semester SY. 2021-2022

EXCEL FUNCTIONS FOR MODELING


SUM AND SUM PRODUCT
Two very useful functions are SUM and SUMPRODUCT.

• The SUM function adds up all of the numbers in a range of cells.


• The SUMPRODUCT function returns the sum of the products of elements in a set of
arrays. SUMPRODUCT is very useful for linear optimization models.
• The SUMPRODUCT function multiplies ranges or arrays together and returns the sum
of products.
• The SUMPRODUCT function returns the sum of the products of corresponding ranges
or arrays. The default operation is multiplication, but addition, subtraction, and division
are also possible.
Example:
In this example, we'll use SUMPRODUCT to return the total sales for a given item and size:

SUMPRODUCT matches all instances of Item Y/Size M and sums them, so for this
example 21 plus 41 equals 62.

IF AND COUNT IF
If Function
• The IF function is one of the most popular functions in Excel, and it allows you to make
logical comparisons between a value and what you expect.

12
Business Analytics 2nd Semester SY. 2021-2022

• So, an IF statement can have two results. The first result is if your comparison is True,
the second if your comparison is False.

Example 1:

=IF(C2=”Yes”,1,2)
The formula says: IF(C2 = Yes, then return a 1, otherwise return a 2)

Example 2:

=IF(C2=1,”Yes”,”No”)
In this example, the formula in cell D2 says: IF(C2 = 1, then return Yes, otherwise return No)

Example 3:

=IF(C2>B2,”Over Budget”,”Within Budget”)

13
Business Analytics 2nd Semester SY. 2021-2022

In the above example, the IF function in D2 is saying IF(C2 Is Greater Than B2, then return
“Over Budget”, otherwise return “Within Budget”)

Example 4:

=IF(C2>B2,C2-B2,0)
In the above illustration, instead of returning a text result, we are going to return a mathematical
calculation. So, the formula in E2 is saying IF(Actual is Greater than Budgeted, then Subtract
the Budgeted amount from the Actual amount, otherwise return nothing).

Count If Function
• COUNTIF is an Excel function to count cells in a range that meet a single condition.
• COUNTIF can be used to count cells that contain dates, numbers, and text.
• The criteria used in COUNTIF supports logical operators (>,<,<>,=) and wildcards (*,?)
for partial matching.

In the worksheet shown above, the following formulas are used in cells G5, G6, and G7:

14
Business Analytics 2nd Semester SY. 2021-2022

V-LOOKUP
• VLOOKUP is an Excel function to look up data in a table organized vertically.
• Lookup values must appear in the first column of the table passed into VLOOKUP.
• VLOOKUP supports approximate and exact matching, and wildcards (* ?) for partial
matches.

V is for vertical
The purpose of VLOOKUP is to get information from a table organized like this:

Using the Order number in column B as a lookup value, VLOOKUP can get the Customer ID,
Amount, Name, and State for any order.
For example, to get the customer name for order 1004, the formula is:
=VLOOKUP(1004,B5:F9,4,FALSE) // returns "Sue Martin"

AUDITING SPREADSHEET MODELS


EXCEL contains a variety of tools to assist you in the development and debugging of
spreadsheet
models.
• These tools are found in the Formula Auditing group of the FORMULAS tab.

15
Business Analytics 2nd Semester SY. 2021-2022

TRACE PRECEDENTS AND DEPENDENTS


• After selecting cells, the Trace Precedents button creates arrows pointing to the
selected cell from cells that are part of the formula in that cell.
• The Trace Dependents button, on the other hand, shows arrows pointing from the
selected cell to cells that depend on the selected cell.
• Both of the tools are excellent for quickly ascertaining how parts of a model are linked.

Trace Precedents Trace Dependents

SHOW FORMULAS
• The Show Formulas button does exactly that.
• To see the formulas in a worksheet, simply click on any cell in the worksheet and then
click on Show Formulas.
• You will see the formulas residing in that worksheet.
• To revert to hiding the formulas, click again on the Show Formulas button.
• The use of Show Formulas allows you to inspect each formula in detail in its cell location.

16
Business Analytics 2nd Semester SY. 2021-2022

EVALUATE FORMULAS
• The Evaluate Formula button allows you to investigate the calculations of a cell in
great detail.
• The Evaluate Formula tool provides an excellent means of identifying the exact
location
of an error in a formula.

Step 1. Select cell with the formula you want to evaluate


Step 2. Click the FORMULAS tab in the Ribbon
Step 3. Click the Evaluate Formula button in the Formula Auditing group
Step 4. When the Evaluate Formula dialog box appears, click the Evaluate
button
Step 5. Repeat Step 4 until the formula has been completely evaluated
Step 6. Click Close

ERROR CHECKING
• The Error Checking button provides an automatic means of checking for mathematical
errors within formulas of a worksheet.
• Clicking on the Error Checking button causes Excel to check every formula in the sheet
for calculation errors.
• If an error is found, the Error Checking dialog box appears.
• The Error Checking procedure is particularly helpful for large models where not all cells
of the model are visible.

17
Business Analytics 2nd Semester SY. 2021-2022

An example for a hypothetical division by zero error is shown below.


The Evaluate Formula Dialog Box After Four Clicks of the Evaluate Button

The Error Checking Dialog Box for A Division by Zero Error

From the box, the formula can be edited, the calculation steps can be observed (as in
the previous section on Evaluate Formulas), or help can be obtained through the Excel help
function.

WATCH WINDOW
• The Watch Window, located in the Formula Auditing group, allows the user to observe
the values of cells included in the Watch Window box list.
• This is useful for large models when not all of the model is observable on the screen or
when multiple worksheets are used.
• The user can monitor how the listed cells change with a change in the model without
searching through the worksheet or changing from one worksheet to another.
18
Business Analytics 2nd Semester SY. 2021-2022

Step 1. Click the FORMULAS tab in the Ribbon


Step 2. Click Watch Window in the Formula Auditing group to display the Watch
Window
Step 3. Click Add Watch. . .
Step 4. Select the cell you would like to add to the watch list

• As shown above, the list gives the workbook name, worksheet name, cell name (if used),
cell location, cell value, and cell formula.
• To delete a cell from the watch list, click on the entry from the list, and then click on the
Delete Watch button that appears in the upper part of the Watch Window.
• The Watch Window allows the user to monitor the value of the selected cell as changes
are made elsewhere in the worksheet.
• If there are other worksheets in the workbook, changes on the selected cell can be
monitored even from the other worksheets.

19

You might also like