2 8 Excel Pivot Table Examples
2 8 Excel Pivot Table Examples
The PivotTable feature is perhaps the most important component in Excel. PivotTable
is making one or more new table from a given data table.
This article is part of my series: Excel Pivot Table Tutorials for Dummies [Step by Step].
The best way to understand pivot table is to see one. Start with the following Figure.
This figure shows a portion of the data we have used creating the pivot tables in this
chapter.
We shall create the Pivot Tables from this data table in this chapter.
Our example shows that data is in a table, but you can make pivot tables from any kind
of data.
1
8 Excel Pivot Table Examples – How to Make a PivotTable!
The above table consists of new account information of a bank. The bank has three
branches: Central, North Country, and Westside. The table has 712 rows. Each row
represents a new account opened at the bank. The table has the following columns:
• What is the total amount of new deposits, broken down by account type and
branch?
• What is the daily total new deposit amount for each branch?
• Which day of the week generates the most deposits?
• How many new bank accounts were opened at each branch, broken down by
account type?
• What’s the dollar distribution of the different account types?
• What types of bank accounts do tellers open most often?
• How does the Central branch compare with the other two branches?
• In which branch do tellers open the most savings accounts for new customers?
You can sort the data and create formulas to answer these questions. But using pivot
table is a better choice, pivot table takes few seconds, doesn't require formula and
produces a professional-looking report.
In addition, analyzing data with pivot tables makes less error than with creating
formulas.
2
8 Excel Pivot Table Examples – How to Make a PivotTable!
Pivot Table Examples
1) What is the total amount of new deposits,
broken down by account type and branch?
Now we shall create a pivot table using the sample file to answer this question. Follow
this process:
If your data is in a worksheet range, just select any cell in the range. We select cell A2 in
our "data" worksheet. Now choose Insert ➪ Tables ➪ PivotTable. The Create
PivotTable dialog box will appear. Excel automatically guess your data range. For this
example, we are going to create our pivot table in a new worksheet. See the following
screenshot:
In the Create PivotTable dialog box, you tell Excel where the data is and where you want
the place the pivot table.
Click OK to choose the options as it is. Excel creates an empty pivot table and displays
a PivotTable Fields task pane. Look at the following figure:
3
8 Excel Pivot Table Examples – How to Make a PivotTable!
We shall use this PivotTable Fields task pane to build our pivot table.
Now we shall work on the PivotTable Fields task pane. PivotTable Fields task pane
has two parts: the upper part, where the field names reside, and the lower part, where
you will place the upper part's field names as per your necessity. In our
example, upper part of PivotTable Fields task pane holds Date, Weekday, Amount,
AcctType, OpenedBy, Branch, Customer fields. The lower part has Filters, Columns,
Rows, and Values area.
1. Drag the Amount field into the Values area. The pivot table will display the
total of all the values in the Amount column.
2. Drag the AcctType field into the Rows area. The pivot table will show now the
total amount for each of the account types.
3. Now, drag the Branch field into the Columns area.The pivot table will show now
the amount for each account type, cross-tabulated by branch. Observe closely.
You will find that total amount of each AccType is calculated on the right side of
the pivot table. At the same time, total amount opened in every branch is also
calculated at the bottom of the pivot table.
4
8 Excel Pivot Table Examples – How to Make a PivotTable!
The following figure gives us our desired Pivot Table. From this Pivot Table, we can find
out easily grand total of amount opened in Westside branch. The pivot table is in "PT1"
sheet. We have changed the sheet name to "PT1" after the creation of pivot table.
5
8 Excel Pivot Table Examples – How to Make a PivotTable!
The pivot table is showing the summary of our data.
Here is a screenshot.
Pivot Table 2.
We want to use conditional formatting to the data range B4: B9 to make you understand
easily which day is making more deposits. To do this select cell range B4: B9 and choose
Home ➪ Style ➪ Conditional Formatting ➪ Data Bars ➪ Gradient Fill ➪ Green Data
Bar.
The pivot table is in "PT3" sheet. We have changed the sheet name to "PT3" after the
creation of pivot table.
6
8 Excel Pivot Table Examples – How to Make a PivotTable!
Using conditional formatting, we have made this pivot table more understandable.
You will get a pivot table, but this one shows the total amount of deposits, broken down
by account types and branch like our first created pivot table. We have to change some
options to get our required one.
Right click on any value of the pivot table and then use the following figure to change
the option.
7
8 Excel Pivot Table Examples – How to Make a PivotTable!
Right click on any value in the pivot table and select Summarize Values By ⇒ Count
After selecting the Count option, our pivot table will look like this.
The pivot table is in "PT4" sheet. We have changed the sheet name to "PT4" after the
creation of pivot table.
8
8 Excel Pivot Table Examples – How to Make a PivotTable!
5) What’s the dollar distribution of the different
account types?
Dollar distribution means, say you may want to know how many accounts were opened
in the range of 1-5000. In our example, total 712 accounts were opened, among them,
253 accounts were opened in the range of 1-5000 range. In percentage, we can say about
35.53% accounts were opened in 1-5000 dollar range.
At first place the Amount field in the rows section at the bottom of the PivotTable
Fields task pane. This will create a figure like this. Right click on any value in the pivot
table, a shortcut menu will appear.
9
8 Excel Pivot Table Examples – How to Make a PivotTable!
When Amount data is placed in Rows section, data is placed ungrouped. To make data in
the group, click the Group option as per this image.
Select Group from the options, Grouping dialog box will appear. Enter 1, 100000, and
5000 in three fields respectively.
10
8 Excel Pivot Table Examples – How to Make a PivotTable!
Place the Amount field again in the Values section. The pivot table will look like this.
11
8 Excel Pivot Table Examples – How to Make a PivotTable!
We have to summarize our pivot table by Count. To do this, right-click on any values, a
shortcut menu will appear and choose Summarize Values By⇒ Count. Your pivot
table will look like this.
Repeat what we have done in step 2. Another same column will be added. Click any cell
in the last column and choose Shows Values as ⇒ % of Grand Total. The table will
look like this.
12
8 Excel Pivot Table Examples – How to Make a PivotTable!
Pivot Table is showing in the percentage of Grand Total.
Change the headers name to Amount, Count, and % of Grand Total respectively. This is
your final pivot table.
The pivot table is in "PT5" sheet. We have changed the sheet name to "PT5" after the
creation of pivot table.
Step 1
Step 2
Now place the AcctType field in the ROWS area in the PivotTable Fields task pane.
Step 3
Now place the Amount field in the VALUES area in the PivotTable Fields task pane.
13
8 Excel Pivot Table Examples – How to Make a PivotTable!
Step 4
Repeat step 3.
Step 5
Right click on any value in the last column and choose Shows Values as ⇒ % of
Grand Total from the shortcut menu.
Step 6
Change the header name of the last two columns to Accounts and PCT respectively.
Step 7
Select cell range C4: C7 and apply this conditional formatting: Home ➪ Style ➪
Conditional Formatting ➪ Data Bars ➪ Gradient Fill ➪ Green Data Bar.
Click OpenedBy drop down list and choose Teller.
The pivot table is in "PT6" sheet. We have changed the sheet name to "PT6" after the
creation of pivot table.
14
8 Excel Pivot Table Examples – How to Make a PivotTable!
You will get a pivot table like this.
Pivot Table when dragged the above fields in the bottom part of the PivotTable Fields task
pane
Now select both North County and Westside columns and right click and
choose Group from the shortcut menu. This will combine these two branches into a
new category (Group 1). Grouping also creates a new field in the PivotTable
Fields task pane. In our case, the new field is named Branch2 in the PivotTable
Fields. You can change the label in the pivot table to Other Branches.
After grouping the North County and Westside branches, you can now easily compare
between the Central branch and the other two branches. See the following figure.
Pivot table when grouped two branches and transformed into one.
15
8 Excel Pivot Table Examples – How to Make a PivotTable!
This pivot table and pivot chart compare the Central branch with the other two
branches combined.
The pivot table is in "PT7" sheet. We have changed the sheet name to "PT7" after the
creation of pivot table.
We have to use three REPORT FILTERS in this pivot table. We have filtered the
Customer Field to show only New, OpenedBy field to show only the Teller, and the
AcctType field to show only Checking. See the following figure.
16
8 Excel Pivot Table Examples – How to Make a PivotTable!
The pivot table is in "PT8" sheet. We have changed the sheet name to "PT8" after the
creation of pivot table.
Happy Excelling :)
17