Show Navigation | Hide Navigation
You are here:
Mapping and visualization > Working with graphs and reports > Looking at data with graphs

Creating a graph

Release 9.2
Last modified November 14, 2006
E-mail This Topic Printable Version Give Us Feedback

Print all topics in : "Looking at data with graphs"


Related Topics

About creating a graph


Before you create a graph, you should determine what sort of information you want to convey. Deciding on whether you wish to show the trends, relationships, distributions or proportions in your data will help you to select the appropriate type of graph.

You can graph all features from a dataset, or just selected ones. The dataset can a feature class, a layer, or an integer raster. You can also graph tabular data. Some graphs can effectively display only a limited amount of data, so choose your graph type appropriately. Alternatively, you might consider making more than one graph.

Graph Wizard


The Create Graph Wizard will lead you through the steps necessary to create a graph. To create a graph, the basic procedure (common to all the available types) is:

  1. Start the Graph wizard.
  2. Select the graph type.
  3. Set the data source.
  4. Select the field to graph.
  5. Set how color will be applied.
  6. Add additional series or functions to the graph, if desired.
  7. Proceed to the second page of the wizard to set the general properties of the final graph (title, etc).
  8. Accept your settings.
Once you complete these steps, the graph will be created in ArcMap as a floating window.

Additional options are available to give further control, as well as specific options that apply to individual types of graphs.

The first page of the graph wizard will appear similar to the following:
Graph Wizard page 1

NOTE: The controls that are displayed will vary slightly depending on the type of graph that is being created.



After all of the series and functions have been specified, proceed to the second page of the wizard to set some of the general properties of the graph:
Graph Wizard page 2

Once a graph has been created, you can return to the wizard and make changes by right-clicking on the graph and selecting Properties. See Modifying a graph for more information on making particular changes.

Once graphs have been created, a right-click anywhere on them will bring up the Graph options context menu, which gives several choices on how to display, store and modify them.


How to create a graph

Creating a simple graph

To become familiar with the way graphs are created in ArcGIS, the following is the basic procedure used to create a simple, common type of graph. The easiest graph to make is a vertical bar graph.

Further details on creating all of the supported types of graphs are contained in the following sections, so look there once you become familiar with the general procedure described here.

  1. The first step is to add a dataset to ArcMap that will contain the data values to graph. Any geographic data layer (feature dataset, layer, integer raster) or table can be used.
  2. Click the Tools menu, point to Graphs, and click on the Create... button Create new graph button to start the graph wizard.
  3. Click the Graph type drop down arrow and select Vertical Bar.
  4. Click the Layer/Table drop down arrow and select the source of the data values you want to graph.
  5. Click the Value field drop down arrow and select the field to graph. The wizard should show the initial version of the graph.
  6. Click Next to get to the second page of the wizard.
  7. If you want to use a different name for the graph, enter it into the Title control of the General graph properties.
  8. Click Finish.
The graph should appear in a new floating window.

Tip

    See the General properties section for more information on the second page of the graph wizard.


Creating a graph from a table


In general the procedure for creating a graph for a table is the same as from a feature layer

  1. Open the table that contains the data values to graph.
  2. Click on the Options drop down menu and select Create Graph... to start the wizard.
  3. Select the field from the table you wish to make a graph from.
  4. In a manner similar to the previous example step, As in the previous example, set any of the other options as desired and complete the wizard to create the graph.


Create a graph with multiple Series


  1. Click the Tools menu, select Graphs, and click Create....
  2. Click the Graph Type drop down arrow and select the type of graph you want to create. In this example, select Vertical Bar.
  3. Click the Layer/Table drop down arrow and select the layer (or table) you wish to graph values from.
  4. Click the Color drop down and select the Custom option. The color of the adjacent button is randomly determined initially, and will be applied to the first series in the graph. If you wish to use a different color, press the Color button button to bring up the color picker.
  5. Click the Value field drop down arrow and select the field you wish to graph.
  6. Click the Add drop down arrow at the bottom of the dialog and select New Series. You will see a tab appear for the new series. The dialog settings will now apply to the new series.
  7. Click the Graph type drop down arrow again and select the type of graph you want to use for the new series. In this example, use Vertical Bar again.
  8. Click the Layer/Table drop down to select the data source of the series you wish to add. It can be the same dataset you used for the first series, or a different one altogether.
  9. Click the Color drop down and select a different color to distinguish the new series from the original one.
  10. Click the Value field drop down to select the field to graph in the new series.
  11. Click Next to move to the second page of the wizard.
  12. Type the Title for the graph in the General Graph Properties.
  13. Click Finish.

Tip


  • Additional series should be set to meaningful Graph types.
  • For example, graphing two or more Bar graphs together is useful, as is combining a Bar and Line graph. However, it is probably is not meaningful to have a Pie graph overlying a Bar graph.


Bar graphs



  1. Click the Tools menu, point to Graphs, and click Create....

  2. Click the Graph type drop down arrow and select the Bar type. The procedure for Vertical and Horizontal bar graphs is similar. For the main difference is that for Vertical bars graphs the Value field's values are distributed along the X (horizontal) axis, and for Horizontal bars they are distributed along the Y (vertical) axis. Further discussion will refer to a vertical bar graph, but the same concept applies to the horizontal graph, so replace the "X field" references to "Y field".

  3. Click the Layer/Table drop down arrow and select the layer or table containing the data values that are to be graphed.

  4. Click the Value field drop down arrow and select the field of values to graph. The wizard will show the initial version of the graph.

  5. The bars of the graph are initially in the order of the data values in the source table. The X field parameter allows you to change the order of the bars based on another field.

  6. For example, you have a table with both economic (GDP) and demographic (population) fields. If you set the Value field to the GDP, and leave the X field as the default <None>, the bars will be sorted based on the order of the values in the table.

    If you then set the X field to a population field, and the type to Ascending, the bars will be sorted with the least populous country on the left side of the graph and subsequent bars for countries with increasing population.

  7. The X label field lets you specify a different field to label the bars in the graph, commonly a text (string) field.

  8. By default, the values of the input data will be added to the legend of the graph. You can disable this by checking off the Add to legend check box.

  9. Click on the Show labels (marks) check box to see the bars in the graph labeled with their actual values. This is useful when there are bars of similar values, where the small difference in bar height may not be easily seen.

  10. You can change the appearance of the bars in the graph with the Color and Bar style controls.

  11. If you have more than one series, click on the Multiple bar type control to change how the bars for those series display together. The bars for different series can be displayed in several ways side by side or stacked on top of each other.

  12. Use the Bar size (%) control to make the bars wider or thinner to your preference.

  13. Click on Show border to draw a perimeter box around each bar in the graph.

  14. The general properties of the graph are set on the second page of the wizard. Click on the Next button to proceed to this page.

  15. NOTE: See the General properties section below for further details.




Histogram graphs



  1. Click the Tools menu, point to Graphs, and click Create....

  2. Click the Graph type drop down arrow and select the Histogram type.

  3. Click the Layer/Table drop down arrow and select the layer or table containing the data values that are to be graphed.

  4. Click the Value field drop down arrow and select the field of values to graph. The wizard will show the initial version of the graph.

  5. Click on the Add to legend check box if you wish to add a legend to the graph.

  6. Click on the Show labels (marks) check box to see the bars in the histogram labeled with the range of values contained in each bin.

  7. You can change the appearance of the bars in the histogram graph with the Color control.

  8. Change the Number of bins control to have more or less bins in the histogram.

  9. The Transparency (%) control allows you to adjust the transparency of the histogram . By default, the histogram graph for each series is opaque (0% transparent). If you have multiple series, you can use the transparency setting to make visible the portions of the histogram that would otherwise be hidden.

  10. Click off the Show border check box if you do not want to see a perimeter line around the histogram.

  11. Click off the Show lines check box if you do not want to see a vertical line differentiating the bins of the histogram.

  12. The general properties of the graph are set on the second page of the wizard. Click on the Next button to proceed to this page.

  13. NOTE: See the General properties section below for further details.




Line graphs



  1. Click the Tools menu, point to Graphs, and click Create....
  2. Click the Graph type drop down arrow and select Line type. The procedure for Vertical and Horizontal line graphs is similar.

  3. The main difference is that for Vertical line graphs the values from the source data field, called the Y field, are plotted on the vertical axis. For Horizontal line graphs, the source data field (X field) values are plotted on the horizontal axis.

    Further discussion refers to a vertical line graph, but the same concept applies to the horizontal line graph. Just replace the "Y field" references to "X field" and "X field" references to "Y field".

  4. Click the Layer/Table drop down arrow and select the layer or table containing the data values that are to be graphed.

  5. Click the Y field drop down arrow and select the field of values to graph. The wizard will show the initial version of the graph.

  6. The points that are connected by lines are initially in the order of the data values in the source table. The optional X field parameter allows you to change the order of the points based on another field.

  7. For example, you have a table with both economic (GDP) and demographic (population) fields. If you set the Value field to the GDP, and leave the X field as the default <None>, the bars will be sorted based on the order of the values in the table.

    If you then set the X field to a population field, and the type to Ascending, the points will be sorted with the least populous country on the left side of the graph and as the population value increases the points will distributed to the right along the horizontal axis.

    If nothing is explicitly set for the X field, the order is the same as in the data table (record 1, record 2, etc...).

  8. The X label field lets you specify a different field to label the bars in the graph, commonly a text (string) field.

  9. By default, the values of the input data will be added to the legend of the graph. You can disable this by clicking the Add to legend check box off.

  10. To mark the data points between the line sections with their actual values, click on the Show labels (marks) check box. This is useful if there are adjacent points of similar value, where the small deviations in the line may not be easily seen.

  11. You can change the appearance of the line segments in the graph with the Color control. The Custom setting will make all of the line segments the same color. Using Palette will allow you to have different colors applied to each line segment, determined from a range of pre-defined palettes.

  12. Use the Stairs mode to control how the data points are connected. When set to Off, the points will be connected directly with angled line segments. The On and Inverted settings connect the data points with horizontal and vertical line segments. This gives a 'stepped' appearance to the line graph. With the On option, the starting point of the line is the data value itself. The Inverted option changes the start point of the line to the next coordinate.

  13. The Line tab allows you to change the Width (thickness) of the line, and its Style (solid, dashed, etc). The Symbol tab allows you to put markers at the locations of the data points. You can change their size (Width and Height), Style (none, circle, star, etc) and Color.

  14. The general properties of the graph are set on the second page of the wizard. Click on the Next button to proceed to this page.

  15. NOTE: See the General properties section below for further details.




Area graphs



  1. Click the Tools menu, point to Graphs, and click Create....
  2. Click the Graph type drop down arrow and select the Area type. The procedure for Vertical and Horizontal Area graphs is similar.

  3. The main difference is that for Vertical Area graphs the values from the source data field, called the Value field, are plotted on the vertical axis. For Horizontal Area graphs, the source data field values are plotted on the horizontal axis.

    Further discussion refers to a Vertical Area graph, but the same concept applies to the Horizontal Area graph. Just replace the "X field" references to "Y field".

  4. Click the Layer/Table drop down arrow and select the layer or table containing the data values that are to be graphed.

  5. Click the Value field drop down arrow and select the field of values to graph. The wizard will show the initial version of the graph.

  6. The points that are connected by the areas are initially in the order of the data values in the source table. The X field parameter allows you to change the order of the points based on another field.

  7. For example, you have a table with both economic (GDP) and demographic (population) fields. If you set the Value field to the GDP, and leave the X field as the default <None>, the bars will be sorted based on the order of the values in the table.

    If you then set the X field to a population field, and the type to Ascending, the points will be sorted with the least populous country on the left side of the graph and as the population value increases the points will distributed to the right along the horizontal axis.

    If nothing is explicitly set for the X field, the order is the same as in the data table (record 1, record 2, etc...).

  8. The X label field lets you specify a different field to label the bars in the graph, commonly a text (string) field.

  9. By default, the values of the input data will be added to the legend of the graph. You can disable this by clicking the Add to legend check box off.

  10. To mark the data points between the line sections with their actual values, click on the Show labels (marks) check box. This is useful if there are adjacent points of similar value, where the small deviations may not be easily seen.

  11. You can change the color of the area segments in the graph with the Color control. The Custom setting will make all of the areas the same color. Using Palette will allow you to have different colors applied to each area, determined from a range of pre-defined palettes.

  12. If you have more than one series, click on the Multiple area type control to change how the areas for those series display together. The areas for different series can be displayed in series order, stacked on top of each other, or stacked as a percentage.

  13. The Stairs mode connects the data points with rectangular areas instead of directly. This gives a 'stepped' appearance to the area graph.

  14. Click on Show border to draw a perimeter line around the area for the series.

  15. The Transparency (%) control allows you to adjust the transparency of the areas. By default, the area graph for each series is opaque (0% transparent). If you have multiple series, you can use the transparency setting to make visible the portions of the area graph for other series that would otherwise be hidden.

  16. The general properties of the graph are set on the second page of the wizard. Click on the Next button to proceed to this page.

  17. NOTE: See the General properties section below for further details.




Scatter Plot graphs



  1. Click the Tools menu, point to Graphs, and click Create....

  2. Click the Graph type drop down arrow and select the Scatter Plot type.

  3. Click the Layer/Table drop down arrow and select the layer or table containing the data values that are to be graphed.

  4. Click the Y field drop down arrow and select the field of values to graph. The wizard will show the initial version of the graph.

  5. The points are initially distributed along the horizontal axis by the order of the values in the source table (record 1, record 2, etc...). The X field parameter allows you to change the order of the points based on another field.

  6. For example, you have a table with state population and area. If you set the Y field to the population, and the X field as the default <None>, the data points of the scatter plot will be distributed along the X axis according to the order of the data values in the table, with the first entry in the table being the left-most point and the last entry the right-most.

    If you then set the X field to the area field, the points will be sorted with the smallest area as the rightmost point and the largest area as the right-most. This can help you see if there is a correlation between the population of a state and its area.

  7. The X label field lets you specify a different field to label the horizontal axis of the scatter plot.

  8. By default, the values of the input data will be added to the legend of the graph. You can disable this by clicking the Add to legend check box off.

  9. To mark the data points with their values, click on the Show labels (marks) check box. If the X label field has not been set, the Y field value will be used for the label value. You can change the field used to label the points with by changing the X label field.

  10. You can change the appearance of the markers on the graph with the Color control.

  11. You can change the appearance of the data points in the scatter plot with the Symbol Properties tabs. The Brush tab controls the size and shape of the points, and the Border tab controls the size, style and color of the perimeter line of the points.

  12. The general properties of the graph are set on the second page of the wizard. Click on the Next button to proceed to this page.

  13. NOTE: See the General properties section below for further details.




Box Plot graphs


Box Plots are a succinct way of demonstrating in a single graphical entity the variability of the values in a series from a dataset. They are often used to compare the variability of several series from either the same dataset or from several different datasets. The description below will describe how to create a box plot of one series, but normally you would use this graph type when you would like to compare several series.


  1. Click the Tools menu, point to Graphs, and click Create....
  2. Click the Graph type drop down arrow and select the Box Plot type.
  3. Click the Layer/Table drop down arrow and select the layer or table containing the data values that are to be graphed.
  4. Click the Value field drop down arrow and select the field of values to graph. The wizard will show the initial version of the graph.
  5. By default, the box plot will not have a legend. You can add a legend to the graph by clicking on the Add to legend check box.
  6. To show the data values in the graph, click on the Show labels (marks) check box.
  7. You can change the color of the markers on the graph with the Color control.
  8. Use the Whisker length control if you wish to change the standard threshold for which data values are considered outliers.

  9. The default value of the whisker length is 1.5, which means that values beyond 1.5 times the length of the box (inter quartile range, or where the middle 50% of the data values lay) are determined to be outliers.

  10. You can change the appearance of the box plot with the Symbol Properties tabs.

  11. Use the Box tab to change the size of the box shape of the graph (relative to the total graph area), and its fill color.

    With the Mild outlier and Extreme outlier tabs you can control the size and shape of the outlier symbols. The fill color of polygonal shapes is determined by the Color control.

    The Whisker tab is used to alter the thickness, style and color of the whiskers of the box plot.

  12. The general properties of the graph are set on the second page of the wizard. Click on the Next button to proceed to this page.

  13. NOTE: See the General properties section below for further details.



Tip

Pie graphs



  1. Click the Tools menu, point to Graphs, and click Create....
  2. Click the Graph type drop down arrow and select the Pie type.
  3. Click the Layer/Table drop down arrow and select the layer or table containing the data values that are to be graphed.
  4. Click the Value field drop down arrow and select the field of values to graph. The wizard will show the initial version of the graph.
  5. The wedges of the graph are initially displayed with the first data value starting at the 3 o'clock position, and subsequent values plotting as subsequent wedges in the counter-clockwise direction. The Sort field allows you to sort the wedges in an ascending or descending order based on another field.
  6. The Label field lets you specify a different field to label the wedges in the graph, commonly a text (string) field.
  7. By default, the values of the input data will be added to the legend of the graph. You can disable this by checking off the Add to legend check box.
  8. Click on the Show labels (marks) check box to see the wedges in the pie labeled with their actual values. This is useful when there are wedges of similar size, where the small difference in their size may not be easily seen.
  9. You can change the color of the wedges in the graph with the Color control.
  10. You can create partial instead of full circles for the pies by reducing the Total Pie angle from its default setting of 360°.
  11. You can adjust in degrees the starting point of the pie graph from its default 3 o'clock position with the Rotate Pie control.
  12. You can highlight the largest single wedge of the pie with the Explode the biggest slice (%) control.
  13. To remove the outline of the pie and all of the wedges, click on the Show border check box to disable it.
  14. The general properties of the graph are set on the second page of the wizard. Click on the Next button to proceed to this page.

  15. NOTE: See the General properties section below for further details.



Controlling pie graphs


For example, you have a table of the human cases of Avian Flu virus by country in a table, in the order of when the virus was first discovered (from 1997 to December, 2005). By default the pie graph will have the wedges in the same order as they are in the table:
Pie graph table and default sort order
If you want to have the wedges in the graph sorted in order of size from largest to smallest, set the Sort field to Cases and the sort type to Descending. The default label field is <None>, but to see the name of the country instead set the Label field to the Country text field (see the left figure below). Alternatively, to have the wedges in alphabetical order by the country name, set the Sort field to Country (right figure below).
Pie graph sorted by size and by string

Tip

    Since Pie graphs do not have axes, any settings in the Axis properties for them will not have any effect.




General properties


The second page of the wizard for creating graphs allows you to control some general properties of the graph regardless of the type of graph or the data source.

Selection




General properties




Legend




Axes




Completing the graph


When you click on the Finish button, the completed graph will display in your ArcMap session.

Once created, graphs can be modified anytime afterwards in the Properties and Advanced Properties.

Please visit the Feedback page to comment or give suggestions on ArcGIS Desktop Help.
Copyright © Environmental Systems Research Institute, Inc.