Anda di halaman 1dari 11

Chapter 9: Working with PivotTable

Creating PivotTable
PivotTable Tools Tabs
PivotTable Field List Task Pane
Applying Style to PivotTable
Exercise 1: Creating PivotTables
Applying Filters and Slicers
Applying Filter
Applying Slicer
Inserting PivotCharts
Exercise 2: Filtering Data and Creating PivotCharts

Chapter 9: Working with PivotTable


In this chapter, you will learn how to use PivotTable and charts.
Once you have created a worksheet, it is not easy to change how your data is organized. The
more complex your worksheet, the more difficult it is to reorganize data for analysis.
This is where you use PivotTable. You can dynamically sort, filter, rearrange and analyze data
dynamically using PivotTable.
You will learn how to create and edit PivotTable from an existing worksheet, format it and use
filters & Slicers to analyze the data.
You will need the data files or workbooks that came with this course for some of the exercises in
this chapter. Please download the workbooks if you have not already done so.

Copyright Trainedge, All Rights Reserved

Creating PivotTable
In Excel 2010, you create a PivotTable from the Insert tab.
Click anywhere in the cell range you want to analyze using the PivotTable. Click on PivotTable
tool in the Tables group on Insert tab.

Excel displays the Create PivotTable dialog box.

Note that Excel automatically selects the cell range or Table/Range you want to use for
PivotTable. If you want to use another data range or it is not automatically selected, you can
manually select it.

Copyright Trainedge, All Rights Reserved

By default, Excel creates the PivotTable in a new worksheet. It is much easier to use PivotTable
on a separate worksheet. But if you want to insert it in the same worksheet, select the Existing
Worksheet radio button and select the location in the worksheet.
Click OK to insert the worksheet and PivotTable.

Excel inserts the worksheet with the PivotTable.

PivotTable Tools Tabs


It displays two PivotTable Tools contextual tabs: Options and Design.

Copyright Trainedge, All Rights Reserved

PivotTable Field List Task Pane


Notice that the worksheet is not displaying any data as you have not selected any field to be
used in the PivotTable. On the right side of the worksheet is the PivotTable Field List task
pane.
The PivotTable Field List displays the list of available fields in the data range in the Choose
fields to add to report area.

At the bottom of the pane, there are four areas in the Drag fields between areas below part.

The four areas are:


Copyright Trainedge, All Rights Reserved

1.
2.
3.
4.

Report Filter
Axis Fields (categories or row labels)
Legend Fields (column labels)
Values

To add a field or column to the PivotTable, drag the field name from the Choose fields to add
to report in the PivotTable Field List task pane to the Drag fields between areas below at
the bottom of the task pane.
You can also right click on the field name and select an option from the contextual menu.

You can drag the fields from one area to another at any time to rearrange your data.
The order in which you enter the fields in the Row Labels and Column Labels areas decides
how Excel organizes data in the PivotTable.
By default Excel adds fields to the following locations:

Nonnumeric fields to the Row Labels.


Numerical fields to the Values area.
Date and time values to the Column Labels.

Applying Style to PivotTable

You can apply many different predefined styles to your PivotTable.

Copyright Trainedge, All Rights Reserved

Click anywhere in the PivotTable to display the contextual tabs. Click More Arrow in the
PivotTable Styles group on the PivotTable Tools Design contextual tab. Excel displays the
PivotTable Styles gallery.

Select a style to apply.

Exercise 1: Creating PivotTables


In this exercise, you will learn how to create a PivotTable, add fields to it and apply styles from
style gallery.
You need the MonthlyWeeklySales workbook located in your practice files for this exercise.
The worksheet has sales data for every week of 2012, grouped by month and quarter.
Open the file and follow the steps:
1. Select any cell in the cell range A1:F49
2. Click PivotTable tool on the Insert tab
3. In the Create PivotTable dialog box, make sure New Worksheet radio button is
selected
4. Click OK. Excel inserts a new worksheet with the PivotTable
Copyright Trainedge, All Rights Reserved

5. Drag Quarter from the Choose fields to add to report and drop in the Report Filter
area in Drag fields between areas below
6. Drag Month from the Choose fields to add to report and drop in the Column Labels
area in Drag fields between areas below
7. Drag Week from the Choose fields to add to report and drop in the Row Labels area
in Drag fields between areas below
8. Drag Weekly Sales Volume from the Choose fields to add to report and drop in the
Values area in Drag fields between areas below
9. Excel displays data in the PivotTable.
10. Click anywhere in the PivotTable to display the contextual tabs.
11. Click More Arrow in the PivotTable Styles group on the PivotTable Tools Design
contextual tab. Excel displays the PivotTable Styles gallery
12. Select a style from gallery. Excel applies it to the PivotTable.
13. Save and Close the workbook.

Applying Filters and Slicers


You can apply filters and slicers to PivotTable to analyze your data.

Applying Filter
Filters limit the amount of data displayed in the PivotTable.
Point the cursor at any field in the Choose fields to add to report in the PivotTable Field List
task pane. Excel displays a down arrow to the right of the field name.

Click the arrow to display the Filter options for the field. Excel displays all values for the field.

Copyright Trainedge, All Rights Reserved

Select the value you want to use as the filter. Excel will only show data that meets the filter
criteria. Click OK to apply the filter.

Applying Slicer
Slicers are also filters but they make it a lot easier and faster to filter the data.
Select any cell in the PivotTable to display the contextual tabs. Click Insert Slicer on the
Options PivotTable Tools contextual tab.

Excel displays the Insert Slicers dialog box. The dialog box lists all fields available in the
PivotTable.
Copyright Trainedge, All Rights Reserved

Select the field you want to use for slicing the data and click OK.
Excel displays the slicer tool for filtering the data. Select the value you want to use as the filter.
Excel slices or filters the data in the PivotTable based on your selection.

Inserting PivotCharts
PivotCharts, like PivotTables, allow you to dynamically analyze your data. Unlike a regular Excel
chart which displays static data, you can dynamically rearrange your data in a PivotChart.
Click anywhere in the PivotTable to display the contextual tabs. Click PivotChart tool in Tools
group on the PivotTable Tools Options contextual tab.
Excel displays the Insert Chart dialog box. Select the chart type and click OK. Excel inserts a
PivotChart in the worksheet.

Copyright Trainedge, All Rights Reserved

You can filter the data displayed in the chart by clicking on the small Down Arrow next to the
field names and then selecting the values you want to display.

Exercise 2: Filtering Data and Creating PivotCharts


In this exercise, you will learn how to apply filters & slicers and insert PivotCharts.
You need the MonthlyWeeklySales workbook located in your practice files for this exercise.
Open the file and follow the steps:
1. Click anywhere inside the PivotTable
2. Point the cursor at Quarter in the Choose fields to add to report in the PivotTable
Field List task pane. Excel displays a down arrow to the right of Quarter.
Copyright Trainedge, All Rights Reserved

3. Click the Down Arrow. Excel displays the Filter options for Quarter field.
4. Select 2012-Q1 and click OK.
5. Excel filters data in the PivotTable to display data for only Q1 (January, February and
March)
6. Click Clear tool in Actions group on the PivotTable Tools Options contextual tab.
7. Click Clear Filters to remove the filter. Excel displays data for all quarters.
8. Click Insert Slicer tool in Sort & Filter group on the PivotTable Tools Options
contextual tab.
9. Excel displays the Insert Slicers dialog box. Select Month and click OK.
10. Excel displays the slicer tool for filtering the data by Month. Click on January. Excel
displays data only for January.
11. Right Click on the Slicer tool and click on Remove Month. Excel removes slicing and
displays data for all months
12. Click PivotChart tool in Tools group on the PivotTable Tools Options contextual tab
13. Excel displays the Insert Chart dialog box. Select the first option under Column charts.
14. Click OK. Excel inserts a column PivotChart in the worksheet.
15. In the PivotChart, click on the small Down Arrow next to Quarter field name.
16. Select 2012-Q3 and click OK
17. The PivotChart displays Weekly Sales Volume for all weeks for the three months in
Quarter 3.
18. Save and close the workbook

Copyright Trainedge, All Rights Reserved

Anda mungkin juga menyukai