7 Data Analysis With Excel
7 Data Analysis With Excel
This section illustrates the powerful features that Excel offers for analyzing
data.
2. To sort in ascending order, on the Data tab, in the Sort & Filter group, click
AZ.
Result:
1. On the Data tab, in the Sort & Filter group, click Sort.
5. Click OK.
Result: records are sorted by Last Name first and Sales second.
Filter Data in Excel
Filter your Excel data to only display records that meet certain criteria. This
is page 1 of 10 in our comprehensive filtering course.
1. Click any single cell inside a data set.
2. On the Data tab, in the Sort & Filter group, click Filter.
4. Click on Select All to clear all the check boxes, and click the check box
next to USA.
5. Click OK.
7. Click on Select All to clear all the check boxes, and click the check box
next to Qtr 4.
8. Click OK.
Result: Excel only displays the sales in the USA in Qtr 4.
9. To remove the filter, on the Data tab, in the Sort & Filter group, click Clear.
To remove the filter and the arrows, click Filter.
11. Right click, and then click Filter, Filter by Selected Cell's Value.
Result: Excel only displays the sales in the USA.
Note: simply select another cell in another column to further filter this data
set.
5. Click OK.
Result: Excel highlights the cells that are greater than 80.
6. Change the value of cell A1 to 81.
Note: you can also use this category (see step 3) to highlight cells that are
less than a value, between two values, equal to a value, cells that contain
specific text, dates (today, last week, next month, etc.), duplicates or unique
values.
Clear Rules
To clear a conditional formatting rule, execute the following steps.
1. Select the range A1:A10.
Top/Bottom Rules
To highlight cells that are above average, execute the following steps.
5. Click OK.
Result: Excel calculates the average (42.5) and formats the cells that are
above this average.
Note: you can also use this category (see step 3) to highlight the top n items,
the top n percent, the bottom n items, the bottom n percent or cells that are
below average.
Create a Chart
To create a line chart, execute the following steps.
2. On the Insert tab, in the Charts group, click the Line symbol.
Note: enter a title by clicking on Chart Title. For example, Wildlife Population.
2. On the Chart Design tab, in the Type group, click Change Chart Type.
4. Click OK.
Result:
Switch Row/Column
If you want to display the animals (instead of the months) on the horizontal
axis, execute the following steps.
2. On the Chart Design tab, in the Data group, click Switch Row/Column.
Result:
Legend Position
To move the legend to the right side of the chart, execute the following
steps.
2. Click the + button on the right side of the chart, click the arrow next to
Legend and click Right.
Result:
Data Labels
You can use data labels to focus your readers' attention on a single data
series or data point.
3. Hold down CTRL and use your arrow keys to select the population of
Dolphins in June (tiny green bar).
4. Click the + button on the right side of the chart and click the check box
next to Data Labels.
Result:
Pivot Tables in Excel
Pivot tables are one of Excel's most powerful features. A pivot table allows you to
extract the significance from a large, detailed data set.
Our data set consists of 213 records and 6 fields. Order ID, Product,
Category, Amount, Date and Country.
3. Click OK.
Drag fields
The PivotTable Fields pane appears. To get the total amount exported of
each product, drag the following fields to the different areas.
1. Product field to the Rows area.
Result:
Note: you can use the standard filter (triangle next to Row Labels) to only
show the amounts of specific products.
4. Click OK.
Tables in Excel
Master Excel tables and analyze your data quickly and easily. Learn how to
create a table, sort a table, filter a table, and much more.
Create a Table
To create a table, execute the following steps.
1. Click any single cell inside the data set.
2. On the Insert tab, in the Tables group, click Table (or simply press Ctrl +
T).
3. Excel automatically selects the data for you. Check 'My table has headers'
and click on OK.
Result: Excel creates a nicely formatted table for you. This may still seem
like a normal data range to you but many powerful features are now just a
click of a button away.
Sort
To sort by Last Name first and Sales second, execute the following steps.
1. First, click the arrow next to Sales and click Sort Smallest to Largest.
2. Next, click the arrow next to Last Name and click Sort A to Z.
Result:
Filter
To filter a table, execute the following steps.
Result:
Total Row
To display a total row at the end of the table, execute the following steps.
1. First, select a cell inside the table. Next, on the Table Design tab, in the
Table Style Options group, check Total Row (or simply press Ctrl + Shift + T).
Result:
2. Click any cell in the last row to calculate the Total (Average, Count, Max,
Min, Sum etc.) of a column. For example, calculate the sum of the Sales
column.
Note: in the formula bar, see how Excel uses the SUBTOTAL function to
calculate the sum. 109 is the argument for Sum if you use the SUBTOTAL
function. Excel uses this function (and not the standard SUM function) to
correctly calculate table totals of filtered tables.
Table Name
Each table has a unique name. You can use this name in formulas. If you like,
you can edit the name of a table.
1. First, select a cell inside the table. Next, on the Table Design tab, in the
Properties group, we can see that Table1 is the name of this table.
2. The formula below refers to Table1 and counts the total number of
records.
Note: visit our page about structured references to learn more about table
formulas.
AutoExpansion
Tables in Excel expand automatically when adding new rows or columns.
This is a great feature.
Assume you own a book store and have 100 books in storage. You sell a
certain % for the highest price of $50 and a certain % for the lower price of
$20.
If you sell 60% for the highest price, cell D10 calculates a total profit of 60 *
$50 + 40 * $20 = $3800.
4. Type a name (60% highest), select cell C4 (% sold for the highest price)
for the Changing cells and click on OK.
5. Enter the corresponding value 0.6 and click on OK again.
Finally, your Scenario Manager should be consistent with the picture below:
Note: to see the result of a scenario, select the scenario and click on the
Show button. Excel will change the value of cell C4 accordingly for you to see
the corresponding result on the sheet.
Scenario Summary
To easily compare the results of these scenarios, execute the following
steps.
2. Next, select cell D10 (total profit) for the result cell and click on OK.
Result:
Conclusion: if you sell 70% for the highest price, you obtain a total profit of
$4100, if you sell 80% for the highest price, you obtain a total profit of
$4400, etc. That's how easy what-if analysis in Excel can be.
Goal Seek
What if you want to know how many books you need to sell for the highest
price, to obtain a total profit of exactly $4700? You can use Excel's Goal
Seek feature to find the answer.
1. On the Data tab, in the Forecast group, click What-If Analysis.
5. Click in the 'By changing cell' box and select cell C4.
6. Click OK.
Result: you need to sell 90% of the books for the highest price to obtain a
total profit of exactly $4700.