Professional Documents
Culture Documents
C 14 Spreadsheet-Based Decision Support Systems: Hapter
C 14 Spreadsheet-Based Decision Support Systems: Hapter
With the increasing use of information technology and availability of high-quality data,
business organizations have a greater need for analyzing data and using this analysis to
guide their decisions. An information system based on decision models is called a decision
support system (DSS). A DSS uses the data residing in spreadsheets and/or databases,
models it, processes or analyzes it using problem-specific methodologies, and assists the
user in the decision-making process through a graphical user interface. In this chapter, we
discuss the usefulness and capabilities of spreadsheet software for developing a DSS.
Spreadsheets are a great option for developing many DSS applications since they are
available with almost any operational system and have many features that are relatively
easy to learn and can be implemented for a large variety of problems.
Keywords: Spreadsheet-based decision support systems; Excel; Visual basic for applica-
tions; Graphical user interface; Procedures; Re-solve options
1 Introduction
The ability to extract data from external sources and embed analytical decision
models within larger systems are two of the most valuable skills required of
entering today’s information technology (IT)-dominated workplace. Model-based
information systems, called decision support systems (DSS), use data residing in
a spreadsheet or a database, model the data, process or analyze it using problem-
specific methodologies, and assist the user in the decision-making process through
a graphical user interface (GUI). A DSS may be developed in various environ-
ments which support data storage, data analysis, solution method development,
and graphical user interface. In this chapter, we discuss the usefulness and cap-
abilities of spreadsheet software for developing a DSS.
In an article by Geoffrion and Krishnan (2001) two well-known researchers in
operations research, state: “The digital economy is creating abundant opportuni-
ties for operations research (OR) applications. … Because OR is well matched to
the needs of the digital economy in certain ways and because certain enabling
conditions are coming to pass, prospects are good for OR to team with related
analytical technologies and join information technology as a vital engine of
278 Michelle M.H. Şeref and Ravindra K. Ahuja
situations (Turban and Aronson 2001). A DSS is not meant to replace a decision
maker, but to extend his/her decision making capabilities. It uses data, provides
a clear user interface, and can incorporate the decision maker’s own insights.
A DSS application contains five components: database, model base, knowledge
base, GUI, and user (see Figure 1). The database stores the data, the model and
knowledge bases store the collections of models and knowledge, respectively, and
the GUI allows the user to interact with the database, model base and knowledge
base. The database and knowledge base can be found in a basic information
system. The knowledge base may contain simple search results for analyzing the
data in the database. For example, the knowledge base may contain the number of
employees in a company database who have worked at the company for over
10 years. A decision support system is an intelligent information system because
of the addition of the model base. The model base includes models used to
perform optimization, simulation, or other algorithms for advanced calculations
and analysis. These models allow the decision support system not only to supply
information to the user but aid the user in making a decision.
Spreadsheet software provides all of the components necessary for a DSS. In
the database component, spreadsheets can easily store relatively large amounts of
data in rows and columns on multiple worksheets. This data can be organized
using sorting features or various formats. In the model base component, spread-
sheet software can perform calculations using spreadsheet functions or a program-
ming language. We will discuss in more detail in the next section the specific
model base features available in common spreadsheet software. In the knowledge
base component, spreadsheets can again be used to store basic knowledge or
280 Michelle M.H. Şeref and Ravindra K. Ahuja
Several spreadsheet software are available for DSS development. We give a brief
overview of these and list specific features of the common spreadsheet software,
Microsoft Excel. We also discuss specific features of Excel’s programming lan-
guage, visual basic for applications (VBA).
The first electronic spreadsheet software, VisiCalc, was introduced in 1978 for the
Apple Computer (Power 2006). Features of this initial program included data
entry and basic accounting calculations. By 1983, Lotus 1-2-3 was introduced for
the IBM PC, using Intel. This software improved on previous offering by adding
charting and database features. Then, Microsoft Excel was introduced (for Apple
in 1985 and for Windows in 1987). At that time, Excel provided an improved user
interface compared to its predecessors and began adding other features. The
software gradually improved to include what-if analysis features (such as goal
seek). More GUI features were then added. These included different data entry
options (such as the validation tool) and basic form features presented in simple
toolbars which placed controls directly on the spreadsheet without any advanced
coding. Next, more-advanced analysis tools were developed such as what’s best
and Frontline System’s solver. Later, other tools, such as simulation tools like
Crystal Ball and @RISK, were made available. Now, programming editors are
available for most spreadsheet softwares to provide more-advanced features and
GUI development options.
Over the past few years, several platforms that allow for the integration of basic
spreadsheet features with more-advanced programming capabilities have become
available. The most common such platform is Microsoft Excel. Excel, which is the
most widely used spreadsheet package among managers and engineers, allows
data storage and model building. Excel also has many built-in programs as well as
many add-on programs available that allow the optimization and simulation of
various models built in Excel. Excel also has a macro programming language,
visual basic for applications (VBA), which allows building of GUIs and
manipulation of Excel objects. Thus, Excel provides a platform in which fairly
sophisticated DSS applications can be built.
Spreadsheet-Based Decision Support Systems 281
Microsoft Excel spreadsheets have become one of the most popular software
packages in the business world, so much so that business schools and engineering
schools have developed several popular Excel-based spreadsheet modeling
courses. Educators of management science claim “spreadsheets [to be] the pri-
mary delivery vehicle for quantitative modeling techniques” (Ragsdale 2001).
A spreadsheet application has functionality for storing and organizing data,
performing various calculations, and using additional packages, called add-ins, for
more-advanced problem solving and analysis. These software packages are
usually quick to learn and provide both basic and advanced features for a variety
of applications.
Microsoft Excel has several features available for data storage and analysis. In
fact, “spreadsheet users often do not use many of the commonly available spread-
sheet features” (Chan and Storey 1996). We describe Excel features in two main
categories: basic functionality and extended functionality features.
Excel basic functionality includes referencing and names, functions and
formulas, charts, and pivot tables. Figure 2 shows an example of some of these
basic features. Referencing and naming cells are key features for a spreadsheet;
they allow the user to develop an entire worksheet of calculations that may
reference one or more cells containing data or preceding calculation results. To
perform calculations in Excel, the user can choose from a large set of predefined
functions or create their own formulas. The predefined functions include simple
calculations (such as sum, average, min, and max) as well as functions in
statistics, finance, referencing, text, logic, and other mathematics categories. Excel
charts are very useful for displaying results to the user. There are several types of
charts available including user-defined charting options. Pivot tables provide
advanced sorting and analysis features for large amounts of data (refer to Figure 3
for an example). They are a very useful tool for finding information as well as
displaying select results. They can also be connected to charts, providing pivoting
features with a graphical display (see Figure 4).
Excel extended functionality includes statistical analysis, mathematical pro-
gramming and optimization using the solver, simulation, and querying large data.
Statistical analysis can be performed using tools such as descriptive statistics and
histograms in the data analysis tool set (refer to Figure 5 for an example of
descriptive statistics output).
The solver is one of Excel’s most popular extended functionality features. The
solver, created by Frontline Systems, allows one to solve linear and integer mathe-
matical programming problems. The solver has an interface in which we define
decision variables, constraints, and objective (refer to Figure 6 for an example).
There is also a new version of the solver, called the premium solver, which
provides nonlinear solution options. Simulation can be performed in Excel using
special functions and formulas. When VBA is used, simulation can be enhanced to
include automatic run execution and animation. Although spreadsheets have some
limit in terms of data storage, Excel has the ability to interface with database
software, namely Microsoft Access, to query large data. This enhances Excel’s
database features by creating collaboration between data stored in a database and
analysis available through Excel’s spreadsheet features.
The basic and extended functionality features in Excel are very appropriate for
building a decision support system. The ability to model a problem and solve or
simulate it adds the model base component of the DSS that we are building. It is
Spreadsheet-Based Decision Support Systems 283
VBA has several features, one of which is recording and running macros. Macros
capture actions performed in Excel and automatically create the corresponding
VBA code. This code can then be run later to perform the actions recorded in
Excel again. The structure of the VBA programming language is object-based.
That is, an Excel object is usually named and then manipulated using properties
(to change certain formatting features of the object) or methods (to perform certain
actions with the object). A set of examples of such object manipulation is shown
in Figure 8; this code was created by recording a macro. The VBA programming
language also includes variables, procedures, programming structures, and arrays.
These are typical features of any programming language. The VBA language is
straightforward to learn, especially but not necessarily for those with experience in
other programming languages.
Additional features of VBA involve creating a user interface. This includes build-
ing user forms, working with several different form controls, using navigational
Spreadsheet-Based Decision Support Systems 287
functions, and designing a clear and professional application. In Figure 9, a user form
is created in the visual basic environment using a control toolbox. This form would
use VBA code to record user input values. VBA can also enhance the modeling,
simulation, and query features of Excel. These are key features in developing a DSS;
that is, one can prompt the user for input by displaying a form, automate a simulation
or perform optimization using VBA. This allows for advanced features to be
implemented without the DSS user having to do more than press a button.
VBA for Excel is an easy to understand programming language. Even if they
have not programmed before, a user should be able to program several types of
applications after learning these features. VBA code allows a DSS developer to
create dynamic applications that can receive user input to form the model base
component of the DSS. VBA is beneficial as it places all of the complicated
spreadsheet calculations and any other analysis in the background of a user-
friendly system.
We now discuss how to develop a DSS application that integrates data, models,
methodologies, and user interfaces in a spreadsheet environment. After learning
how to work in the Excel spreadsheet environment and how to program in VBA to
manipulate Excel objects and perform advanced calculations and analysis, one can
then combine these tools to develop a complete spreadsheet-based DSS appli-
cation. Before entering formulas into Excel or coding procedures in VBA, it is
necessary to plan the overall layout for the DSS and give some thought to the
design and implementation of the application.
We propose six basic steps for developing a DSS; these steps have been our
guidelines in developing decision support systems. We do not claim that it is ne-
cessary to follow these, but rather consider them helpful guidelines when devel-
oping a DSS application (Şeref et al. 2006).
1. Application overview and model development: Create a layout of the
entire application, designing the flow from the user input to the model
calculations to the output, and outlining the model details.
2. Worksheets: Determine how many worksheets the programmer requires
to best handle input, calculations, and output.
3. User interface: Outline what interface a programmer requires to receive
input from the user and navigate him or her through the application.
4. Procedures: Outline what programming procedures are required to
receive input, perform calculations, and display output.
288 Michelle M.H. Şeref and Ravindra K. Ahuja
5. Re-solve options: Decide what re-solve options the user will be given.
6. Testing and final packaging: Ensure that the application is working
properly and has a clear and professional appearance.
By following these steps, one can ensure that the DSS is designed in an efficient
manner to meet the user’s needs. In the spreadsheet environment, all input can be
sufficiently collected and stored, simple calculations as well as advanced problem
solving can be performed, and output can be displayed clearly to the user.
Spreadsheets are thus a friendly environment for both the DSS developer as well
as the end user.
Using the DSS development process described above with the features available in
Excel and VBA, several spreadsheet-based DSS applications can be efficiently
developed. Some possible DSS applications that a manager may want to use may
include a facility or warehouse layout DSS, an inventory management DSS,
a forecasting DSS, a staff or production scheduling DSS, a reliability analysis
DSS, or a queuing simulation DSS. Other business analysis applications may
include an option pricing DSS, a stock investment DSS, a retirement planning
DSS, or a capital budgeting DSS. (We refer the reader to Şeref et al. 2006 for
detailed examples of these DSS applications.)
Below we describe a portfolio management and optimization DSS developed in
Excel using VBA. We will describe the DSS based on the development process
proposed in the previous section.
Model: The underlying model for optimizing the portfolio investment plan
minimizes risk as the objective. We define the risk of the portfolio as the sum of
Spreadsheet-Based Decision Support Systems 289
the product of the variance and the square of the investment over all stocks plus
the total covariance factor for all stocks in the portfolio. The model is subject to
certain constraints including: the cash invested must be less than or equal to the
cash available for investing; the return on the portfolio must be greater than or
equal to the minimum return desired for the entire portfolio; and the amount
invested per stock must be less than or equal to the maximum amount to be
invested in each stock. Here, the return on the portfolio is defined as the sum of
the product of the investment amount and the expected return over all stocks. We
use the premium solver to solve this nonlinear programming problem.
User inputs: Portfolio (selected stocks), total cash for investing, minimum return
desired, and maximum amount to invest per stock.
DSS data: Stock information (including quarterly price and annual return),
covariance between all stocks, and quarterly price variance and mean as well as
annual return mean calculations.
Outputs: Returns earned, cash used, portfolio return per stock, and optimal
amount to invest per stock.
Worksheets: We use nine worksheets in this application: the welcome sheet, four
data sheets, two information sheets, a model sheet, and an output sheet.
First data sheet: “All Stocks” This sheet contains the complete list of stocks
available for this application. The sheet lists each stock’s name and category, as
well as its quarterly price for five quarters (including the current price) and the
annual return for five years.
Third data sheet: “Portfolio” This sheet records the information from the “All
Stocks” sheet for the stocks in the user’s portfolios. We will also use this sheet
later to perform some calculations for the optimization. These calculations are for
the mean price over five quarters, the variance in price for each quarter, the sum of
the variances, and the sum of the annual returns.
Fourth data sheet: “Chart Data” This contains data copied from the “All Stocks”
data sheet for a set of stocks selected by the user. The copied data is used to
produce charts that are shown on one of the information sheets. If the user has
selected to plot the change in market price, then we copy the quarterly prices for
the selected stocks from the “All Stocks” sheet and paste them on the first table
shown. If the user has selected to plot the annual returns, then we copy the annual
returns from the “All Stocks” sheet and paste them on the second table shown. Two
graphs on the “Compare Stocks” information sheet refer to these tables as their
source data.
First user input sheet: “Create/Edit Portfolio” In this sheet, the user can create
or modify their portfolio by performing one of the two following actions: selecting
several stocks from the “All Stocks” list and clicking the “Add” arrow button to
add these stocks to their portfolios; or selecting several stocks from the “Portfolio”
list and clicking the “Remove” arrow button to remove these stocks from their
portfolios. This is the first sheet that the user visits after clicking the “Start” button
on the “Welcome” sheet. If the user is not sure which stocks are best to add or
remove from their portfolios, they can click the “Compare All Stocks” button to
proceed to the second information sheet: the “Compare Stocks” sheet. Otherwise,
if they feel their portfolio is complete, they can click the “Save Portfolio and
Return to Main Menu” button to return to the Main Menu. The “Exit” button
allows the user to exit the application.
Second user input sheet: “Compare Stocks” This sheet allows the user to select
several stocks from the “All Stocks” list and plot either their annual returns or the
change in market price. The user selects one of these options from the combo box
on the worksheet and then presses the “Show Plot” button. The corresponding
chart then appears. We create these charts using the data from the fourth data
sheet. The user can then return to the “Create/Edit Portfolio” sheet by clicking the
“Return to Create/Edit Portfolio” button. The user can also exit the application at
this point by clicking the “Exit” button.
Model sheet: The model sheet lists all of the stocks in the portfolio with adjacent
cells for the investment amount. These are the changing cells whose values are
determined when optimization is performed. These values, solved as percentages,
are converted into dollar amounts in the next column. We refer to the dollar
amounts to check the constraint that each stock receives less than or equal to the
maximum investment amount per stock. The code then calculates the expected
return and variance and displays these figures in the next two columns. We use
these values in the third column; and the sum of this column is the risk value. This
risk value, in the “Minimum Risk” cell at the top of the sheet, is the objective
function cell. The code procedures also calculate the formulas for the forth
column: the covariance factors. These factors are calculated for all pairs of stocks
in the portfolio using the stock in each row as the pivot. The total covariance
factor is the sum of the values in this column. The “Min Return” and “Unit
Constraint” columns capture the other two constraints. We then use the premium
294 Michelle M.H. Şeref and Ravindra K. Ahuja
solver with the objective function as the “Minimum Risk” cell and the constraints
as the minimum return, maximum stock investment, and unit constraint cells. The
solver’s nonlinear algorithm is used to find a solution, if one exists.
Output sheet: “Investment Report” This sheet displays a graph of the invest-
ment amounts for each stock in the user’s portfolio as well as the corresponding
values in an adjacent table. The minimized risk, or variance, of the portfolio is
also provided. The return and desired return are displayed, as well as the cash used
and the total cash available. The “Modify Input” and “Modify Portfolio” buttons
correspond to two re-solve options, which we discuss later. The “View Model”
button allows the user to view the model sheet, and the “Exit” button allows them
to exit the application.
User interface: We use two user forms, one control on a worksheet, and several
navigational and functional buttons for the user interface for this DSS.
First form: “Main Menu” The first form that the user sees is the “Main Menu”.
It provides them with three navigational options: create a new portfolio, edit their
current portfolio, or optimize their portfolio investment plan. If the user selects to
create a new portfolio, then they are taken to the “Create/Edit Portfolio” sheet,
which is cleared of past data. If the user selects to edit their current portfolio, then
they are taken to the same sheet, except no clearing is done. If the user selects to
optimize their portfolio investment plan, then an optimization procedure is run and
the user is taken to the output sheet.
Second form: “Minimize Risk” When the user selects “Optimize Portfolio Invest-
ment Plan” from the “Main Menu” form, they will see the optimization input form:
“Minimize Risk”. This form prompts the user for three optimization inputs: the total
cash available to make the investment, the minimum desired return on the portfolio,
and the maximum amount they can invest per stock.
Worksheet user control: “Compare Stocks Combo Box” This control is on the
“Compare Stocks” worksheet. It is a combo box that lists the two plot options:
“Change in Market Price” and “Annual Return”. Once the user makes a selection,
they can use the “Show Plot” functional button to display the plot for the selected
stocks.
Re-solve options: This application consists of two re-solve options, which are
associated with the “Modify Input” and “Modify Portfolio” buttons on the output
sheet. If the user clicks “Modify Input,” then the optimization input form is
displayed again. The user can modify their input values, press “OK,” and the
optimization will be re-performed. If the user selects the “Modify Portfolio”
button, they will return to the “Create/Edit Portfolio” sheet. They can then modify
their portfolio and click the “Save Portfolio and Return to Main Menu” button to
return and select the optimization button again. The optimization will then be re-
performed.
Thus, using Excel and VBA, a complete portfolio management and optimi-
zation DSS can be developed. This spreadsheet-based DSS allows the user to view
Spreadsheet-Based Decision Support Systems 297
several stocks and compare stock data, select a portfolio, and find the optimal
investment plan which minimizes investment risk while achieving a minimum
return value.
5 Alternatives to Spreadsheets
6 Conclusion
Spreadsheets are an excellent option for developing many DSS applications since
they are available for almost any operational system and have many features that
are relatively easy to learn and can be implemented for a large variety of problems.
With the increasing demand for IT-based systems and quick decision making,
spreadsheet-based DSS are an important and necessary tool for any industry. Thus,
students and professionals should learn the basic process for developing a DSS.
Spreadsheets are an attractive environment for developing a DSS as they can be
easily found and quickly learned. Once the tools of spreadsheet software and
a programming language are learnt, an efficient and user-friendly DSS application
can be created for almost any situation.
298 Michelle M.H. Şeref and Ravindra K. Ahuja
Acknowledgements
We thank the referees for their insightful comments and suggestions which led to
an improved presentation of the chapter. The second author gratefully acknow-
ledges the support of NSF Grant # 4506177 given for the course curriculum
development.
References