Excel for Microsoft 365 Excel for Microsoft 365 for Mac Excel 2021 Excel 2021 for Mac Excel 2019 Excel 2019 for Mac Excel 2016 Excel 2016 for Mac Excel 2013 Excel 2010 Excel 2007 Excel for Mac 2011 More…Less
By using What-If Analysis tools in Excel, you can use several different sets of values in one or more formulas to explore all the various results.
For example, you can do What-If Analysis to build two budgets that each assumes a certain level of revenue. Or, you can specify a result that you want a formula to produce, and then determine what sets of values will produce that result. Excel provides several different tools to help you perform the type of analysis that fits your needs.
Note that this is just an overview of those tools. There are links to help topics for each one specifically.
What-If Analysis is the process of changing the values in cells to see how those changes will affect the outcome of formulas on the worksheet.
Three kinds of What-If Analysis tools come with Excel: Scenarios, Goal Seek, and Data Tables. Scenarios and Data tables take sets of input values and determine possible results. A Data Table works with only one or two variables, but it can accept many different values for those variables. A Scenario can have multiple variables, but it can only accommodate up to 32 values. Goal Seek works differently from Scenarios and Data Tables in that it takes a result and determines possible input values that produce that result.
In addition to these three tools, you can install add-ins that help you perform What-If Analysis, such as the Solver add-in. The Solver add-in is similar to Goal Seek, but it can accommodate more variables. You can also create forecasts by using the fill handle and various commands that are built into Excel.
For more advanced models, you can use the Analysis ToolPak add-in.
A Scenario is a set of values that Excel saves and can substitute automatically in cells on a worksheet. You can create and save different groups of values on a worksheet and then switch to any of these new scenarios to view different results.
For example, suppose you have two budget scenarios: a worst case and a best case. You can use the Scenario Manager to create both scenarios on the same worksheet, and then switch between them. For each scenario, you specify the cells that change and the values to use for that scenario. When you switch between scenarios, the result cell changes to reflect the different changing cell values.
1. Changing cells
2. Result cell
1. Changing cells
2. Result cell
If several people have specific information in separate workbooks that you want to use in scenarios, you can collect those workbooks and merge their scenarios.
After you have created or gathered all the scenarios that you need, you can create a Scenario Summary Report that incorporates information from those scenarios. A scenario report displays all the scenario information in one table on a new worksheet.
Note: Scenario reports are not automatically recalculated. If you change the values of a scenario, those changes will not show up in an existing summary report. Instead, you must create a new summary report.
If you know the result that you want from a formula, but you’re not sure what input value the formula requires to get that result, you can use the Goal Seek feature. For example, suppose that you need to borrow some money. You know how much money you want, how long a period you want in which to pay off the loan, and how much you can afford to pay each month. You can use Goal Seek to determine what interest rate you must secure in order to meet your loan goal.
Cells B1, B2, and B3 are the values for the loan amount, term length, and interest rate.
Cell B4 displays the result of the formula =PMT(B3/12,B2,B1).
Note: Goal Seek works with only one variable input value. If you want to determine more than one input value, for example, the loan amount and the monthly payment amount for a loan, you should instead use the Solver add-in. For more information about the Solver add-in, see the section Prepare forecasts and advanced business models, and follow the links in the See Also section.
If you have a formula that uses one or two variables, or multiple formulas that all use one common variable, you can use a Data Table to see all the outcomes in one place. Using Data Tables makes it easy to examine a range of possibilities at a glance. Because you focus on only one or two variables, results are easy to read and share in tabular form. If automatic recalculation is enabled for the workbook, the data in Data Tables immediately recalculates; as a result, you always have fresh data.
Cell B3 contains the input value.
Cells C3, C4, and C5 are values Excel substitutes based on the value entered in B3.
A Data Table cannot accommodate more than two variables. If you want to analyze more than two variables, you can use Scenarios. Although it is limited to only one or two variables, a Data Table can use as many different variable values as you want. A Scenario can have a maximum of 32 different values, but you can create as many scenarios as you want.
If you want to prepare forecasts, you can use Excel to automatically generate future values that are based on existing data, or to automatically generate extrapolated values that are based on linear trend or growth trend calculations.
You can fill in a series of values that fit a simple linear trend or an exponential growth trend by using the fill handle or the Series command. To extend complex and nonlinear data, you can use worksheet functions or the regression analysis tool in the Analysis ToolPak Add-in.
Although Goal Seek can accommodate only one variable, you can project backward for more variables by using the Solver add-in. By using Solver, you can find an optimal value for a formula in one cell—called the target cell—on a worksheet.
Solver works with a group of cells that are related to the formula in the target cell. Solver adjusts the values in the changing cells that you specify—called the adjustable cells—to produce the result that you specify from the target cell formula. You can apply constraints to restrict the values that Solver can use in the model, and the constraints can refer to other cells that affect the target cell formula.
Need more help?
You can always ask an expert in the Excel Tech Community or get support in the Answers community.
See Also
Scenarios
Goal Seek
Data Tables
Using Solver for capital budgeting
Using Solver to determine the optimal product mix
Define and solve a problem by using Solver
Analysis ToolPak Add-in
Overview of formulas in Excel
How to avoid broken formulas
Detect errors in formulas
Keyboard shortcuts in Excel
Excel functions (alphabetical)
Excel functions (by category)
Need more help?
Want more options?
Explore subscription benefits, browse training courses, learn how to secure your device, and more.
Communities help you ask and answer questions, give feedback, and hear from experts with rich knowledge.
Содержание
- What-If Analysis with Data Tables
- One-variable Data Tables
- Analysis with One-variable Data Table
- Step 1: Set the required background
- Step 2: Create the Data Table
- Step 3: Do the analysis with the What-If Analysis Data Table Tool
- Two-variable Data Tables
- Analysis with Two-variable Data Table
- Step 1: Set the required background
- Step 2: Create the Data Table
- Do the analysis with the What-If Analysis Tool Data Table
- Data Table Calculations
- Speeding up the Calculations in a Worksheet
- From Excel Options
- From the Ribbon
- Introduction to What-If Analysis
- Need more help?
What-If Analysis with Data Tables
With a Data Table in Excel, you can easily vary one or two inputs and perform What-if analysis. A Data Table is a range of cells in which you can change values in some of the cells and come up with different answers to a problem.
There are two types of Data Tables −
- One-variable Data Tables
- Two-variable Data Tables
If you have more than two variables in your analysis problem, you need to use Scenario Manager Tool of Excel. For details, refer to the chapter – What-If Analysis with Scenario Manager in this tutorial.
One-variable Data Tables
A one-variable Data Table can be used if you want to see how different values of one variable in one or more formulas will change the results of those formulas. In other words, with a one-variable Data Table, you can determine how changing one input changes any number of outputs. You will understand this with the help of an example.
There is a loan of 5,000,000 for a tenure of 30 years. You want to know the monthly payments (EMI) for varied interest rates. You also might be interested in knowing the amount of interest and Principal that is paid in the second year.
Analysis with One-variable Data Table
Analysis with one-variable Data Table needs to be done in three steps −
Step 1 − Set the required background.
Step 2 − Create the Data Table.
Step 3 − Perform the Analysis.
Let us understand these steps in detail −
Step 1: Set the required background
Assume that the interest rate is 12%.
List all the required values.
Name the cells containing the values, so that the formulas will have names instead of cell references.
Set the calculations for EMI, Cumulative Interest and Cumulative Principal with the Excel functions – PMT, CUMIPMT and CUMPRINC respectively.
Your worksheet should look as follows −
You can see that the cells in column C are named as given in the corresponding cells in column D.
Step 2: Create the Data Table
Type the list of values i.e. interest rates that you want to substitute in the input cell down the column E as follows −
As you observe, there is an empty row above the Interest Rate values. This row is for the formulas that you want to use.
Type the first function (PMT) in the cell one row above and one cell to the right of the column of values. Type the other functions (CUMIPMT and CUMPRINC) in the cells to the right of the first function.
Now, the two rows above the Interest Rate values look as follows −
The Data Table looks as given below −
Step 3: Do the analysis with the What-If Analysis Data Table Tool
Select the range of cells that contains the formulas and values that you want to substitute, i.e. select the range – E2:H13.
Click the DATA tab on the Ribbon.
Click What-if Analysis in the Data Tools group.
Select Data Table in the dropdown list.
Data Table dialog box appears.
- Click the icon in the Column input cell box.
- Click the cell Interest_Rate, which is C2.
You can see that the Column input cell is taken as $C$2. Click OK.
The Data Table is filled with the calculated results for each of the input values as shown below −
If you can pay an EMI of 54,000, you can observe that the interest rate of 12.6% is suitable for you.
Two-variable Data Tables
A two-variable Data Table can be used if you want to see how different values of two variables in a formula will change the results of that formula. In other words, with a twovariable Data Table, you can determine how changing two inputs changes a single output. You will understand this with the help of an example.
There is a loan of 50,000,000. You want to know how different combinations of interest rates and loan tenures will affect the monthly payment (EMI).
Analysis with Two-variable Data Table
Analysis with two-variable Data Table needs to be done in three steps −
Step 1 − Set the required background.
Step 2 − Create the Data Table.
Step 3 − Perform the Analysis.
Step 1: Set the required background
Assume that the interest rate is 12%.
List all the required values.
Name the cells containing the values, so that the formula will have names instead of cell references.
Set the calculation for EMI with the Excel function – PMT.
Your worksheet should look as follows −
You can see that the cells in the column C are named as given in the corresponding cells in the column D.
Step 2: Create the Data Table
Type =EMI in cell F2.
Type the first list of input values, i.e. interest rates down the column F, starting with the cell below the formula, i.e. F3.
Type the second list of input values, i.e. number of payments across row 2, starting with the cell to the right of the formula, i.e. G2.
The Data Table looks as follows −
Do the analysis with the What-If Analysis Tool Data Table
Select the range of cells that contains the formula and the two sets of values that you want to substitute, i.e. select the range – F2:L13.
Click the DATA tab on the Ribbon.
Click What-if Analysis in the Data Tools group.
Select Data Table from the dropdown list.
Data Table dialog box appears.
- Click the icon in the Row input cell box.
- Click the cell NPER, which is C3.
- Again, click the icon in the Row input cell box.
- Next, click the icon in the Column input cell box.
- Click the cell Interest_Rate, which is C2.
- Again, click the icon in the Column input cell box.
You will see that the Row input cell is taken as $C$3 and the Column input cell is taken as $C$2. Click OK.
The Data Table gets filled with the calculated results for each combination of the two input values −
If you can pay an EMI of 54,000, the interest rate of 12.2% and 288 EMIs are suitable for you. This means the tenure of the loan would be 24 years.
Data Table Calculations
Data Tables are recalculated each time the worksheet containing them is recalculated, even if they have not changed. To speed up the calculations in a worksheet that contains a Data Table, you need to change the calculation options to Automatically Recalculate the worksheet but not the Data Tables, as given in the next section.
Speeding up the Calculations in a Worksheet
You can speed up the calculations in a worksheet containing Data Tables in two ways −
- From Excel Options.
- From the Ribbon.
From Excel Options
- Click the FILE tab on the Ribbon.
- Select Options from the list in the left pane.
Excel Options dialog box appears.
From the left pane, select Formulas.
Select the option Automatic except for data tables under Workbook Calculation in the Calculation options section. Click OK.
From the Ribbon
Click the FORMULAS tab on the Ribbon.
Click the Calculation Options in the Calculations group.
Select Automatic Except for Data Tables in the dropdown list.
Источник
Introduction to What-If Analysis
By using What-If Analysis tools in Excel, you can use several different sets of values in one or more formulas to explore all the various results.
For example, you can do What-If Analysis to build two budgets that each assumes a certain level of revenue. Or, you can specify a result that you want a formula to produce, and then determine what sets of values will produce that result. Excel provides several different tools to help you perform the type of analysis that fits your needs.
Note that this is just an overview of those tools. There are links to help topics for each one specifically.
What-If Analysis is the process of changing the values in cells to see how those changes will affect the outcome of formulas on the worksheet.
Three kinds of What-If Analysis tools come with Excel: Scenarios, Goal Seek, and Data Tables. Scenarios and Data tables take sets of input values and determine possible results. A Data Table works with only one or two variables, but it can accept many different values for those variables. A Scenario can have multiple variables, but it can only accommodate up to 32 values. Goal Seek works differently from Scenarios and Data Tables in that it takes a result and determines possible input values that produce that result.
In addition to these three tools, you can install add-ins that help you perform What-If Analysis, such as the Solver add-in. The Solver add-in is similar to Goal Seek, but it can accommodate more variables. You can also create forecasts by using the fill handle and various commands that are built into Excel.
For more advanced models, you can use the Analysis ToolPak add-in.
A Scenario is a set of values that Excel saves and can substitute automatically in cells on a worksheet. You can create and save different groups of values on a worksheet and then switch to any of these new scenarios to view different results.
For example, suppose you have two budget scenarios: a worst case and a best case. You can use the Scenario Manager to create both scenarios on the same worksheet, and then switch between them. For each scenario, you specify the cells that change and the values to use for that scenario. When you switch between scenarios, the result cell changes to reflect the different changing cell values.
1. Changing cells
1. Changing cells
If several people have specific information in separate workbooks that you want to use in scenarios, you can collect those workbooks and merge their scenarios.
After you have created or gathered all the scenarios that you need, you can create a Scenario Summary Report that incorporates information from those scenarios. A scenario report displays all the scenario information in one table on a new worksheet.
Note: Scenario reports are not automatically recalculated. If you change the values of a scenario, those changes will not show up in an existing summary report. Instead, you must create a new summary report.
If you know the result that you want from a formula, but you’re not sure what input value the formula requires to get that result, you can use the Goal Seek feature. For example, suppose that you need to borrow some money. You know how much money you want, how long a period you want in which to pay off the loan, and how much you can afford to pay each month. You can use Goal Seek to determine what interest rate you must secure in order to meet your loan goal.
Cells B1, B2, and B3 are the values for the loan amount, term length, and interest rate.
Cell B4 displays the result of the formula =PMT(B3/12,B2,B1).
Note: Goal Seek works with only one variable input value. If you want to determine more than one input value, for example, the loan amount and the monthly payment amount for a loan, you should instead use the Solver add-in. For more information about the Solver add-in, see the section Prepare forecasts and advanced business models, and follow the links in the See Also section.
If you have a formula that uses one or two variables, or multiple formulas that all use one common variable, you can use a Data Table to see all the outcomes in one place. Using Data Tables makes it easy to examine a range of possibilities at a glance. Because you focus on only one or two variables, results are easy to read and share in tabular form. If automatic recalculation is enabled for the workbook, the data in Data Tables immediately recalculates; as a result, you always have fresh data.
Cell B3 contains the input value.
Cells C3, C4, and C5 are values Excel substitutes based on the value entered in B3.
A Data Table cannot accommodate more than two variables. If you want to analyze more than two variables, you can use Scenarios. Although it is limited to only one or two variables, a Data Table can use as many different variable values as you want. A Scenario can have a maximum of 32 different values, but you can create as many scenarios as you want.
If you want to prepare forecasts, you can use Excel to automatically generate future values that are based on existing data, or to automatically generate extrapolated values that are based on linear trend or growth trend calculations.
You can fill in a series of values that fit a simple linear trend or an exponential growth trend by using the fill handle or the Series command. To extend complex and nonlinear data, you can use worksheet functions or the regression analysis tool in the Analysis ToolPak Add-in.
Although Goal Seek can accommodate only one variable, you can project backward for more variables by using the Solver add-in. By using Solver, you can find an optimal value for a formula in one cell—called the target cell—on a worksheet.
Solver works with a group of cells that are related to the formula in the target cell. Solver adjusts the values in the changing cells that you specify—called the adjustable cells—to produce the result that you specify from the target cell formula. You can apply constraints to restrict the values that Solver can use in the model, and the constraints can refer to other cells that affect the target cell formula.
Need more help?
You can always ask an expert in the Excel Tech Community or get support in the Answers community.
Источник
There are some Microsoft Excel features that are awesome but somewhat hidden. And the «data table analysis» is one of them.
Sometimes a formula depends on multiple inputs, and you’d like to see how different inputs values would impact the result. The data table is perfect for that situation.
This is extremely useful to analyze a problem in Excel and figure out the best solution.
The Dataset
To use the data table feature we will need some data.
Here’s a table with 2 inputs (book price and quantity sold), and a formula (revenue = price * quantity).
If we sell 100 books at $29 each, we will make $2,900.
The data above assume we know the book price and how many copies we will sell. But we’re actually not sure, so we’d like to know the revenue for different combination of price and quantity. For example: how much profit will we make if we sell 150 copies instead of 100, and what if the price is $19 or $49?
There are 2 main ways to do that:
- Manually change the 2 inputs, and see how the result change.
- Do that automatically with the data table feature.
Nobody likes doing repetitive tasks manually, so let’s try the second option
The Set Up
Before we start using the data table, we need to do some changes to our data.
First we need to copy the formula to a separate place. You can do this by simply typing =C4 in a blank cell.
Then we need to tell Excel what values we would like to test. To the right of the formula we list all the prices ($19, $29, $49), and below the formula we list all the quantities (25, 50, 100).
And we can add some basic formatting (borders and currency) to make things look slightly better.
Our goal is to fill this table with the profit for each combination of price and quantity.
Data Table Example
Now we can start the interesting part!
Select the new table we just created, and in the «data» tab, click on the «what if analysis» button. There select «data table».
A popup will appear that you need to fill like this:
- Row input cell: we listed the price at the top, so the «row input» is the price, which is in C2.
- Column input cell»: we listed the quantity in the left, so the «column input» is the quantity, which is in C3.
Press OK, and we are done. Excel did the math for us, and automatically updated the spreadsheet with all the numbers we wanted.
Now we can see exactly how much revenue we will make based on the different combination of inputs. For example it shows that selling 50 copies at $49 will make us $2,450. That’s super powerful.
Limitations
For your information, using data tables have some drawbacks. Here I listed three limitations that make me most uncomfortable:
- The performance and calculation speed of an Excel file will be slowed down if it contains many data tables.
- The structure of the data table is fixed. You will get an error message if you try to insert a row or column in a data table, or if you delete just a single cell in it.
- The data table must be located on the same tab as the setup data table (as mentionned above in the Set Up section). You cannot link the data table to cells on a different tab.
Conclusion
With just a few clicks, we can get Excel to do some magic computation and give us interesting information.
For this example we had a simple formula. But you could do the same on something much more complex, and Excel will give you the perfect answer in no time.
What-If Analysis in Excel is a tool that helps us create different models, scenarios, and Data Tables. This article will look at the ways of using What-If Analysis.
Table of contents
- What is a What-If Analysis in Excel?
- #1 Scenario Manager in What-If Analysis
- #2 Goal Seek in What-If Analysis
- #3 Data Table in What-If Analysis
- Things to Remember
- Recommended Articles
We have three parts of What-If Analysis in Excel. They are as follows:
- Scenario Manager
- Goal Seek in Excel
- Data Table in Excel
You can download this What-If Analysis Excel Template here – What-If Analysis Excel Template
#1 Scenario Manager in What-If Analysis
As a business head, it is important to know the different scenarios of your future project. Based on the scenarios, the business head will make decisions. For example, you are going to undertake one of the important projects. You have done your homework and listed all the possible expenditures from your end, and below is the list of all your expenses.
The expected cash flow from this project is $75 million, which is in cell C2. Total expenses comprise all your fixed and variable expenses, the total cost is $57.45 million in cell C12. Total profit is $17.55 million in cell C14, and profit % is 23.40% of your cash inflow.
It is the basic scenario of your project. Now, you need to know the profit scenario if some of your expenses increase or decrease.
Scenario 1
- In a general case scenario, you have estimated the “Project License” cost to be $10 million, but you are sure anticipating it to be $15 million
- Raw material costs to be increased by $2.5 million
- Other expensesOther expenses comprise all the non-operating costs incurred for the supporting business operations. Such payments like rent, insurance and taxes have no direct connection with the mainstream business activities.read more to be decreased by 50 thousand.
Scenario 2
- The “Project Cost” to be at $20 million
- The “Labor Daily Wages” to be at $5 million
- The “Operating Cost” is to be at $3.5 million
Now, you have listed out all the scenarios in the form. Based on these scenarios, you need to create a table about how it will impact your profit and profit %.
To create What-If Analysis scenarios, follow the below steps.
- Go to DATA > What-If Analysis > Scenario Manager.
- Once you click “Scenario Manager,” it will show you below the dialog box.
- Click on “Add.” Then, give “Scenario name.”
- In changing cells, select the first scenario changes you have listed out. The changes are Project License (cell C10) at $15 million, Raw Material Cost (cell C7) at $11 million, and Other Expenses (cell C11) at $4.5 million. Mention these three cells here.
- Click on “OK.” It will ask you to mention the new values as listed in scenario 1.
- Do not click on “OK” but click on “OK Add.” It will save this scenario for you.
- Now, it will ask you to create one more scenario. As we listed in scenario 2, make the changes. This time we need to change Project Cost (C10), Labour Cost (C8), and Operating Cost (C9).
- Now, add new values here.
- Now click on “OK.” It will show all the scenarios we have created.
- Click on “Scenario summary.” It will ask you which result cells you want to change. Here, we need to change the Total Expense Cell (C12), Total Profit Cell (C14), and Profit % cell (C16).
- Click on “OK.” It will create a summary report for you in the new worksheet.
Total Excel has created three scenarios even though we have supplied only two scenario changes because Excel will show existing reports as one scenario.
From this table, we can easily see the impact of changes in pour profit %.
#2 Goal Seek in What-If Analysis
Now, we know the Scenario Manager’s advantage. What-if-Analysis Goal Seek can tell you what you must do to achieve the target.
Andrew is a class 10th student. His target is to achieve an average score of 85 in the final exam. He has already completed 5 exams and left with only 1 exam. Therefore, in the completed 5 exams.
To calculate the current average, apply the average formula in the B7 cell.
The current average is 82.2.
Andrew’s GOAL is 85. His current average is 82.2. He is short by 3.8 with one exam.
Now, the question is how much he has to score in the final exam to eventually get an overall average of 85. It can be found by the What-If Analysis GOAL SEEK tool.
- Step 1: Go to DATA > What-If Analysis > Goal Seek.
- Step 2: It will show you below the dialog box.
- Step 3: Here, we need to set the cell first. “Set cell” is nothing but which cell we need for the final result, i.e., our overall average cell (B7). Next is “To value.” Again, Andrew’s overall average GOAL is nothing but for what value we need to set the cell (85).
The next and final step is changing which cell you want to see the impact on. So, we need to change cell B6, the cell for the final subject’s score.
- Step 4: Click on “OK.” Excel will take a few seconds to complete the process, but it eventually shows the result like the one below.
Now, we have our results here. To get an overall average of 85, Andrew has to score 99 in the final exam.
#3 Data Table in What-If Analysis
We have already seen two wonderful techniques under What-If Analysis in Excel. First, the Data Table can create different scenario tables based on the variable change. We have two kinds of Data Tables here: one variable Data Table and a “Two-variable data tableA two-variable data table helps analyze how two different variables impact the overall data table. In simple terms, it helps determine what effect does changing the two variables have on the result.read more.” This article will show you One variable data table in ExcelOne variable data table in excel means changing one variable with multiple options and getting the results for multiple scenarios. The data inputs in one variable data table are either in a single column or across a row.read more.
Assume you are selling 1,000 products at ₹15, your total anticipated expense is ₹12,500, and your profit is ₹2,500.
You are not happy with the profit you are getting. Your anticipated profit is ₹7,500. You have decided to increase your per-unit price to increase your profit, but you do not know how much you need to increase.
Data tables can help you. Create a table below.
Now, in the cell, F1 links to the “Total Profit” cell, B6.
- Step 1: Select the newly created table.
- Step 2: Go to DATA > What-if Analysis > Data Table.
- Step 3: Now, you will see below dialog box.
- Step 4: Since we are showing the result vertically, leave the ”Row input cell.” In the “Column input cell,” select cell B2, which is the original selling price.
- Step 5: Click on “OK” to get the results. It will list out profit numbers in the new table.
So, we have our Data Table ready. To profit from ₹7,500, you need to sell at ₹20 per unit.
Things to Remember
- The What-If Analysis data table can be performed with two variable changes. Refer to our article on What-If Analysis two-variable Data Table.
- What-If Analysis Goal Seek takes a few seconds to perform calculations.
- What-If Analysis Scenario Manager can give a summary with input numbers and current values together.
Recommended Articles
This article is a guide to What-If Analysis in Excel. Here, we discuss three types of What-If Analysis in Excel such as 1) Scenario Manager, 2) Goal Seek, 3) Data Tables along with practical examples, and a downloadable Excel template. You may learn more about Excel from the following articles: –
- Pareto Analysis in ExcelA pareto chart is a graph which is a combination of a bar graph and a line graph, indicates the defect frequency and its cumulative impact. It helps in finding the defects to observe the best possible and overall improvement measure.read more
- Goal Seek in VBA
- Sensitivity Analysis in Excel
With a Data Table in Excel, you can easily vary one or two inputs and perform What-if analysis. A Data Table is a range of cells in which you can change values in some of the cells and come up with different answers to a problem.
There are two types of Data Tables −
- One-variable Data Tables
- Two-variable Data Tables
If you have more than two variables in your analysis problem, you need to use Scenario Manager Tool of Excel. For details, refer to the chapter – What-If Analysis with Scenario Manager in this tutorial.
One-variable Data Tables
A one-variable Data Table can be used if you want to see how different values of one variable in one or more formulas will change the results of those formulas. In other words, with a one-variable Data Table, you can determine how changing one input changes any number of outputs. You will understand this with the help of an example.
Example
There is a loan of 5,000,000 for a tenure of 30 years. You want to know the monthly payments (EMI) for varied interest rates. You also might be interested in knowing the amount of interest and Principal that is paid in the second year.
Analysis with One-variable Data Table
Analysis with one-variable Data Table needs to be done in three steps −
Step 1 − Set the required background.
Step 2 − Create the Data Table.
Step 3 − Perform the Analysis.
Let us understand these steps in detail −
Step 1: Set the required background
-
Assume that the interest rate is 12%.
-
List all the required values.
-
Name the cells containing the values, so that the formulas will have names instead of cell references.
-
Set the calculations for EMI, Cumulative Interest and Cumulative Principal with the Excel functions – PMT, CUMIPMT and CUMPRINC respectively.
Your worksheet should look as follows −
You can see that the cells in column C are named as given in the corresponding cells in column D.
Step 2: Create the Data Table
-
Type the list of values i.e. interest rates that you want to substitute in the input cell down the column E as follows −
-
Type the first function (PMT) in the cell one row above and one cell to the right of the column of values. Type the other functions (CUMIPMT and CUMPRINC) in the cells to the right of the first function.
Now, the two rows above the Interest Rate values look as follows −
As you observe, there is an empty row above the Interest Rate values. This row is for the formulas that you want to use.
The Data Table looks as given below −
Step 3: Do the analysis with the What-If Analysis Data Table Tool
-
Select the range of cells that contains the formulas and values that you want to substitute, i.e. select the range – E2:H13.
-
Click the DATA tab on the Ribbon.
-
Click What-if Analysis in the Data Tools group.
-
Select Data Table in the dropdown list.
Data Table dialog box appears.
- Click the icon in the Column input cell box.
- Click the cell Interest_Rate, which is C2.
You can see that the Column input cell is taken as $C$2. Click OK.
The Data Table is filled with the calculated results for each of the input values as shown below −
If you can pay an EMI of 54,000, you can observe that the interest rate of 12.6% is suitable for you.
Two-variable Data Tables
A two-variable Data Table can be used if you want to see how different values of two variables in a formula will change the results of that formula. In other words, with a twovariable Data Table, you can determine how changing two inputs changes a single output. You will understand this with the help of an example.
Example
There is a loan of 50,000,000. You want to know how different combinations of interest rates and loan tenures will affect the monthly payment (EMI).
Analysis with Two-variable Data Table
Analysis with two-variable Data Table needs to be done in three steps −
Step 1 − Set the required background.
Step 2 − Create the Data Table.
Step 3 − Perform the Analysis.
Step 1: Set the required background
-
Assume that the interest rate is 12%.
-
List all the required values.
-
Name the cells containing the values, so that the formula will have names instead of cell references.
-
Set the calculation for EMI with the Excel function – PMT.
Your worksheet should look as follows −
You can see that the cells in the column C are named as given in the corresponding cells in the column D.
Step 2: Create the Data Table
-
Type =EMI in cell F2.
-
Type the first list of input values, i.e. interest rates down the column F, starting with the cell below the formula, i.e. F3.
-
Type the second list of input values, i.e. number of payments across row 2, starting with the cell to the right of the formula, i.e. G2.
The Data Table looks as follows −
Do the analysis with the What-If Analysis Tool Data Table
-
Select the range of cells that contains the formula and the two sets of values that you want to substitute, i.e. select the range – F2:L13.
-
Click the DATA tab on the Ribbon.
-
Click What-if Analysis in the Data Tools group.
-
Select Data Table from the dropdown list.
Data Table dialog box appears.
- Click the icon in the Row input cell box.
- Click the cell NPER, which is C3.
- Again, click the icon in the Row input cell box.
- Next, click the icon in the Column input cell box.
- Click the cell Interest_Rate, which is C2.
- Again, click the icon in the Column input cell box.
You will see that the Row input cell is taken as $C$3 and the Column input cell is taken as $C$2. Click OK.
The Data Table gets filled with the calculated results for each combination of the two input values −
If you can pay an EMI of 54,000, the interest rate of 12.2% and 288 EMIs are suitable for you. This means the tenure of the loan would be 24 years.
Data Table Calculations
Data Tables are recalculated each time the worksheet containing them is recalculated, even if they have not changed. To speed up the calculations in a worksheet that contains a Data Table, you need to change the calculation options to Automatically Recalculate the worksheet but not the Data Tables, as given in the next section.
Speeding up the Calculations in a Worksheet
You can speed up the calculations in a worksheet containing Data Tables in two ways −
- From Excel Options.
- From the Ribbon.
From Excel Options
- Click the FILE tab on the Ribbon.
- Select Options from the list in the left pane.
Excel Options dialog box appears.
-
From the left pane, select Formulas.
-
Select the option Automatic except for data tables under Workbook Calculation in the Calculation options section. Click OK.
From the Ribbon
-
Click the FORMULAS tab on the Ribbon.
-
Click the Calculation Options in the Calculations group.
-
Select Automatic Except for Data Tables in the dropdown list.