Jan's Illustrated Computer Literacy 101 Logo:Jegsworks Jan's Illustrated Computer Literacy 101


Home > Jan's CompLit 101 > Working with Numbers > Basics > Finish > Chart
Icon: Arrow - Previous pagePrevious    NextIcon: Arrow - Next page

Jan's Working with Numbers

    Excel Basics: Finish: Chart

Numbers do not make the same impact on the brain as a picture. A chart is not only prettier than a list of numbers, it actually is a better way to show you how the numbers compare. 

Chart: Pie From a pie chart you can immediate tell when certain items take up a big part of the whole.

Button: Column Chart (Excel 2010) From a column chart you can easily compare values to each other.

Button: Line Chart (Excel 2010) A line chart shows trends well over time.


Icon Step-by-Step 

Step-by-Step: Pie Chart

 Icon Step-by-Step

What you will learn: to create a Pie Chart
to change the chart type with context menu
to change the chart type with ribbon button
to select data source
to modify a chart layout by adding data labels
to move chart to its own sheet
to add a text box to chart

Start with: Icon: Class disk trips7-Lastname-Firstname.xlsx (saved in previous lesson)

Create a Pie Chart

You are going to create a pie chart to show the number of people who were booked for trips during each of the eight weeks of the special sales promotion. This makes it easy to see how each week compares to the whole.

  1. Icon: Class disk Save As trips8-Lastname-Firstname.xlsx to your Class disk in the excel project2 folder.
  2. Select the row labels and data cells for the pie chartSelect range A27:A35, hold down the CTRL key, and drag to select range C27:C35.
    Both ranges are now selected. These are the row labels and the data cells for the number of people who bought trips each week during the special sales promotion.
  3. On the Insert tab in the Charts tab group, click on the Pie Chart button Chart: Pie Button: Pie Chart (Excel 2013).
    A list of types of pie charts opens.
  4. Click on the first 2D chart type.

    Button: Pie Chart > 2D (Excel 2010) Ribbon: Insert > Pie Chart > 2D (Excel 2013)

    The chart appears in the middle of the page and the Chart Tools tabs appear in the ribbon.

    Pie Chart with incorrect pie wedges (Excel 2010)

    Pie Chart with incorrect pie wedges (Excel 2013)

    This chart does not look quite right, not counting the fact that Excel 2013 and 2016 have a somewhat different style for the pie and put the legend at the bottom instead of the right.

    • Title is "Week" instead of "# of people".
    • The legend looks OK, 1, 2, 3....
    • Sizes of the pie wedges does not match column C values of 9, 23, 18, 18....
      They increase in size starting from the top center.

    What happened??

    Excel has put the first column of data (1, 2, 3, ...) in the pie instead of the second column (9, 23, 18, etc.). The values in the first column are the row labels for the chart but they are numbers instead of the text that Excel expects for row labels. That's why the legend looked right. Whoops indeed!

    A pie chart can only show one series of data, so Excel is showing just column as that series. If you had chosen a bar or column chart type, it would be clear immediately that there was a problem. You would see two sets of bars.

    Let's look at the data in a column chart and then you will fix this problem!

    Icon: TipText for row labels: Avoid using plain numbers as row labels or else format those numbers as text.

    TipOrder of wedges in pie chart: The first item in the legend of a pie chart always has its left edge at the top center. The next item is to its right, clockwise.

  5. Icon: Class disk Save.
    [trips8-Lastname-Firstname.xlsx]

Change Chart Type

There are two ways to open the Change Chart Type dialog: the context menu for a chart and the Chart Tools: Design ribbon tab.

Context Menu:

  1. Right Click Menu: Change Chart Type (Excel 2010)Right click on a blank area of the chart.
    A context menu appears.
  2. Click on Change Chart Type.
    The Change Chart Type dialog appears.

  3. Click on Column and then on the first choice, 2D and then on OK.
    Icon: Excel 2013 Icon: Excel 2016 Excel 2013, 2016: The dialog shows thumbnails of some common choices and uses the actual data. Nice feature.

    Dialog: Change Chart Type > Column > 2D (Excel 2010) Dialog: Change Chart Type - Two column (Excel 2013)

    Column Chart: two data series (Excel  2010)The chart changes and shows two data series in different colors. That shows that there is a problem.

    The legend for the chart shows that Excel is using the data from column A, label 'Week', as the first series. Now we can clearly see what Excel is trying to do! Too bad Excel is only partly smart when it does so much to 'help'.

Ribbon tab:

  1. If necessary, switch to the tab Chart Tools: Design.

    Ribbon: Chart Tools: Design > Change Chart Type (Excel 2007)

    Ribbon: Chart Tools: Design > Change Chart Type (Excel 2013)

  2. Click on the button Change Chart Type.
    The dialog Change Chart Type opens again.
  3. Dialog: Change Chart Type > Pie > 2D (Excel 2010)Click on Pie and then on the 2D flat style again.

    Dialog: Change Chart Type > Pie > 2D (Excel 2013)Excel 2013 and 2016 offer two choices. The one on the right is what we are trying to get! But don't pick it this time.

  4. Click on OK.
    Your chart is back to the incorrect Pie Chart.

  5. Icon: Class disk Save.
    [trips8-Lastname-Firstname.xlsx]

    Pie Chart with incorrect pie wedges (Excel 2010) Pie Chart with incorrect pie wedges (Excel 2013)


Select Data

Now you can fix the pie chart settings by changing the data source for the chart. Then it will show the correct pie slices.

  1. Right Click Menu: Select Data... (Excel 2010)Right click on a blank area of the chart.
    A context menu appears.
  2. Click on Select Data...
    The Select Data Source dialog appears.
    This dialog lets you manually edit or re-select the cells to use for a data series or for the labels.

    Dialog: Select Data Source - original data for pie chart (Excel 2010)The dialog shows two series on the left, named 'Week' and '# of people'. 'Week' is selected. There are no cells listed on the right to use as labels for the chart. Instead there are just numbers.

     
    The text box at the top, Chart data range, shows which cells are in the chart.
     Data range incorrectly includes labels

    TipThe sheet's name is separated from the range with an exclamation point, !, which you can read as "bang".

  3. With Week selected on the left of the dialog, click the Remove button.

    There is only one series left on the left, # of people. The data range at the top changes to match.

  4. Dialog: Axis Labels (Excel 2010)Click on the right on the Edit button for the Horizontal (Category) Axis Labels.
    The dialog Axis Labels appears. You can type in cell references here or drag in the worksheet.
     
  5. Dialog: Axis Labels - A28:A35 (Excel 2010)Drag from A28 to A35.
    When you start to drag, the dialog gets smaller to help you see what you are doing (whether you needed the help this time or not). When you release the mouse, the dialog enlarges again. It shows the complete cell reference for these cells, including the sheet name.

    If a dialog of this type is in the way of where you need to click or drag, you can click the Collapse Dialog button Button: Collapse dialog at the right end of the text box. You can also drag it out of the way by dragging its title bar.

  6. When you finish selecting the cells, click the Restore Dialog button Button: Restore Dialog.

  7. Click on OK
    The chart automatically reflects your changes. It now correctly shows pie wedges for the number of people. These wedges are different sizes than in the first version. When checking your work, the details are important!

    Chart fixed Chart fixed (Excel 2013)

  8. Icon: Class disk Save.
    [trips8-Lastname-Firstname.xlsx]
    Now you are ready to format the chart.

Add Data Labels to Chart

You can change the formatting of just about every piece of this chart yourself. You can also add some features. 

  1. Ribbon: Chart Tools: Design: Quick Layout > Layout 6 (Excel 2013)

    Ribbon: Chart Tools: Design > Chart Layouts > Layout 6 (Excel 2010)On the Chart Tools: Design tab in the Chart Layouts tab group, open the Layouts palette

  2. Click on Layout 6.
    This layout adds data labels for the percent each wedge is of the whole.

    Pie Chart with percent data labels (Excel 2010) Pie Chart with percent data labels (Excel 2013)

    The pre-designed layouts are not all you can do!

  3. Position Data labels:

    Ribbon: Chart Tools: Layout > Data Labels > Outside End (Excel 2010)Icon: Excel 2007 Icon: Excel 2010 Excel 2007, 2010: On the Chart Tools: Layouts tab in the Labels tab group, click on Data Labels.
    The menu of choices appears.

    Ribbon: Chart Tools: Add Element > Data Labels > Outside End (Excel 2013)Icon: Excel 2013 Icon: Excel 2016 Excel 2013, 2016: On the Chart Tools: Layouts tab, click the button Add Chart Element.
    A menu of choices appears.

    Hover over Data Labels.
    A sub menu appears.

  4. Click on Outside End.
    This choice moves the percentages to outside the pie, beside their wedges.

    Pie chart with percentages moved outside the pie. (Excel 2010) Pie chart with percentages moved outside the pie. (Excel 2010)

  5. Icon: Class disk Save.
    [trips8-Lastname-Firstname.xlsx]

Move Chart to Sheet 2 

A chart can appear on a sheet with data cells (which might be blank) or on a special Chart sheet alone. The Chart-type sheets fill the screen and the printed page with the chart. That is not always a good use of ink!

Excel 2007 and 2010 by default have 3 blank sheets in a new workbook. But Excel 2013and 2016 have only one sheet in a new blank document.

  1. Button: Add Sheet (Excel 2013)Icon: Excel 2013 Icon: Excel 2016 Excel 2013, 2016: Beside the Sheet 1 tab at the bottom of the window, click the Add Sheet button Button: Add Sheet.
    The default name for the new sheet is Sheet2, unless you have already added other sheets. Even if you have deleted sheets, Excel keeps count for this session and increases the sheet number for the next sheet that you add.
  2. If necessary, switch back to Sheet1 by clicking its tab and then click on the chart to select it.
  3. Dialog: Move Chart > Object in > Sheet2 (Excel 2010)On the Chart Tools: Design tab at the right end of the ribbon in the Location tab group by itself, click on the button
    Move Chart
    Button: Move Chart (Excel 2010).
    The Move Chart dialog opens.
    You have choices!
    Icon: Chart sheet (Excel 2010) New sheet = only the chart shows
    Icon: Object in - existing sheet Object in = existing sheet with data cells, which may or may not be empty
  4. Chart of # of PeopleClick the arrow to open the list for the text box 'Object in'.
  5. Click on Sheet2.
    The chart moves over onto Sheet2 in the same location as it was on Sheet1. Surprise!
    Depending on your window size, the chart may be out of sight!
  6. If necessary, scroll to find the chart on Sheet2 and drag the chart by its border to the upper left corner of the worksheet.
    You may need to scroll to get there.
  7. To change the sheet's name, double-click the tab for Sheet2 at the bottom of the window.
  8. Type Pie Chart - people and press the ENTER key.
  9. Click outside the chart to deselect it.
  10. Icon: Class disk Save.
    [trips8-Lastname-Firstname.xlsx]

Add Text Box to Chart

The legend is not really clear at this point. What do those numbers mean? They are the weeks of the special offers promotion. You can add a title for the legend, with a little help from the ribbon.

  1. Select the chart on its new sheet.
  2. To add a text box to the chart:
    Icon: Excel 2007 Icon: Excel 2010 Excel 2007, 2010: Switch to the ribbon tab Chart Tools: Layout. In the Insert tab group, click on the button Text Box.
    Text Box shape in palette of shapes (Excel 2013)Icon: Excel 2013 Icon: Excel 2016 Excel 2013, 2016: On the ribbon tab Chart Tools: Format in the Insert Shapes tab group, click on the Text Box shape in the palette of shapes.
  3. Move the mouse pointer over the chart area above the legend.
    Your mouse pointer has changed shape, Pointer: Text Box , to a sword shape. This is the shape used to create a text box.
  4. Default text box showing 'Week'Click in the chart area above the legend.
    A text box appears.
  5. Type Week.
    This text is likely not centered well over your legend. You must resize and position the text box.
  6. Drag the bottom right handle of the text box up and left until the box is just large enough to hold the text.
  7. Move the mouse pointer over the edge of the text box until the pointer changes to the Move shapePointer: Move shape.
  8. Text box resized and positioned over the legendDrag the box until it is centered over the legend.
  9. If necessary, click on the legend to see its borders and drag the whole set left until the legend and its new label line up nicely.
  10.  Icon: Class disk Save.
    [trips8-Lastname-Firstname.xlsx]

 trips8-Lastname-Firstname.xlsx - chart done