Geoprocessing tools are essential for spatial analysis, but they have other uses as well. Spatial analysis includes activities such as comparing places, determining how places are related, finding best locations and paths, detecting patterns, and making predictions. Most geoprocessing tools work on an input dataset to create an output dataset. Some tools modify the attributes or geometry of an input dataset. A few tools have other effects, such as creating selections on layers or generating messages or reports.
- Video length: 2:43.
- This video was created with ArcGIS Pro 2.3.
In this tutorial, you'll use geoprocessing tools to solve a spatial problem.
- Estimated time: 45 minutes
- Software requirements: ArcGIS Pro
Open the project
Nassella tussock is an invasive weed accidentally brought to New Zealand in the late 1800s. It is now well established in the Marlborough and Canterbury regions on the South Island. It spreads quickly, crowds out other grasses, and is hard to eradicate. It is unpalatable to livestock, which makes it a threat to pastoral farming. Nassella tussock seeds are spread mainly by wind, but also by animals, people, and vehicles.
In this tutorial, you'll look for Nassella tussock growing near commercial campgrounds (campgrounds for motorhomes). Campers who come in contact with the weed during recreational activities may get seeds in their clothing or gear and take these seeds with them when they leave. If your analysis shows that Nassella tussock grows near commercial campgrounds, agriculture officials can provide information to help campers identify and avoid it.
The analysis has three parts. First, you'll create buffers, or proximity zones, around the commercial campgrounds. Next, you'll see which of these buffers contain Nassella tussock. Finally, you'll calculate the amount of Nassella tussock within the buffers.
- Start ArcGIS Pro and sign in if necessary.
- On the start page, under your recent projects, click Open another project.
If you already have a project open, click the Project tab on the ribbon. In the list of menu items on the left, click Open. On the Open page, click Portal and click Open another project at the bottom of the page.
- On the Open Project dialog box, under Portal , click ArcGIS Online .
- At the top of the dialog box, in the Search box, type Use geoprocessing tools tutorial and press the Enter key.
- In the list of search results, click Use geoprocessing tools to select the project package.
If there is more than one project package with this name, look at the Owner column. Select the item with the owner name ArcGISProTutorials. If you don't get any results, see No search results are returned.
- Click OK.
The project opens to the Marlborough region of New Zealand. Commercial campgrounds are displayed along with the known distribution of Nassella tussock.
The Nassella Tussock Range layer does not represent the density of the plant at a given location. A marked area may be heavily infested or it may have only scattered plants.
Open the Geoprocessing pane
To carry out the analysis, you'll run tools from the Geoprocessing pane. First, you'll see how these tools are organized in ArcGIS Pro.
- On the ribbon, click the View tab. In the Windows group, click Reset Panes and click Reset Panes for Geoprocessing.
This ensures that the Contents, Catalog, and Geoprocessing panes are open and that other panes are closed. In the Geoprocessing pane, on the Favorites tab, some common geoprocessing tools, including Buffer, are readily accessible.
You can also access the Geoprocessing pane without resetting other panes. To do so, on the Analysis tab on the ribbon, in the Geoprocessing group, click Tools .
- In the Geoprocessing pane, click the Toolboxes tab.
You see a list of toolboxes organized by category.
- Browse to Analysis Tools > Proximity.
A toolbox may contain built-in tools , script tools , or model tools . It may also contain toolsets , which are smaller containers of tools. See Geoprocessing vocabulary to learn more about tool types.
The Proximity toolset contains tools for analyzing distances between and around features.
- In the Proximity toolset, click Buffer.
The Buffer tool opens in the Geoprocessing pane. Some of its parameters are blank; others have default values. Required parameters are marked with a red asterisk.
- Hover over the Help button .
A ScreenTip describes and illustrates the tool. The Buffer tool creates distance zones around features. Buffers are typically used to find features in one layer near features in another layer. In this case, you will look for Nassella tussock near campgrounds.
Buffer the commercial campgrounds
Now you'll set the parameters and run the tool.
- On the Buffer tool, click the Input Features drop-down arrow and click Commercial Campgrounds.
If you have an ArcGIS Pro Advanced license, you may notice that the Side Type and End Type parameters are removed when you set the input features. These parameters are not used with point feature buffers. If you have an ArcGIS Pro Basic or Standard license, these parameters are not available and you won't see them at all. See ArcGIS Desktop license levels for general information about license level differences.
- Change the default Output Feature Class name to Campground_Buffers.
When you hover over the Output Feature Class parameter, the full path to the project geodatabase is displayed. You can either highlight and replace the dataset name at the end of the path or delete the entire path and type the new feature class name. The full path will be restored automatically when the tool is run.
Feature class names cannot include spaces. Use the underscore character to separate words.
- In the Distance [value or field] box, type 1.5.
- Click the adjacent drop-down list of distance units and click Kilometers.
The tool will create a polygon feature class containing 14 buffer features, one for each campground. The buffer features will be circles of a 1.5-kilometer radius centered on the campgrounds. Your assumption is that campers are most likely to come in contact with Nassella tussock on walks and bike rides.
- Hover over any tool parameter, such as Method or Dissolve Type.
An information icon appears next to the parameter.
When you hover over the information icon, a ScreenTip describes the parameter and its settings. You'll accept the default values for the Method and Dissolve Type parameters.
- At the bottom of the Geoprocessing pane, click Run .
When the tool finishes running, a completion message appears at the bottom of the Geoprocessing pane.
On the completion message, click or hover over View Details to see information about the process.
A new feature class named Campground_Buffers is created in your project geodatabase, and a layer is added to the map. At the current map scale, the buffers are probably obscured by the campground symbols.
In the Geoprocessing pane, a warning icon appears next to the Output Feature Class parameter. This means that the feature class name has now been used. If you run the tool again without changing the name, you will overwrite existing data.
- In the Contents pane, turn off the Commercial Campgrounds layer.
- Right-click the Campground_Buffers layer and click Zoom To Layer .
The default symbol is partially transparent, but you'll change it to an outline to get a better look at Nassella tussock inside the buffers.
- In the Contents pane, click the symbol for the Campground_Buffers layer.
The Symbology pane appears and displays formatting options for the polygon symbol.
- At the top of the Symbology pane, click the Gallery tab if necessary.
- In the search box, type outline and press the Enter key.
In the ArcGIS 2D style, a few symbols are found. You can hover over the symbols to get more information.
- Click the Black Outline (1pt) symbol to select it.
The symbols are updated on the map.
- In the Contents pane, right-click the Campground_Buffers layer name and click Attribute Table .
In the Campground_Buffers table, the name and address attributes have been copied from the Commercial Campgrounds layer that was the input to the Buffer tool. The BUFF_DIST field shows the buffer distance expressed in meters.
- Close the attribute table.
- On the ribbon, click the Map tab. Zoom in and examine some buffers to see whether they contain Nassella tussock.
- When you're finished, in the Navigate group, click Bookmarks and click Campgrounds.
- On the Quick Access Toolbar, click Save to save the project.
Select buffers containing Nassella tussock
A visual inspection is helpful, but analysis is a better way to find out which buffers contain Nassella tussock. Two common methods for finding features of interest are Select By Attributes , which analyzes table attributes, and Select By Location , which analyzes spatial relationships. In this case, you want to find features in one layer (Campground_Buffers) that have area in common with features in another layer (Nassella Tussock Range), so you'll use Select By Location.
- In the Contents pane, click the Campground_Buffers layer to select it if necessary.
- On the ribbon, on the Map tab, in the Selection group, click Select By Location .
The Select By Location window appears.
For convenience, some geoprocessing tools open in a floating window. These tools can also be opened in the Geoprocessing pane.
A key parameter for this tool is the spatial relationship to be evaluated. Depending on the situation, you may want to know whether features intersect, contain, touch, or lie within a certain distance of other features.
In this situation, containment might seem to be the right relationship because you want to find campground buffers that contain Nassella tussock. However, this choice is too restrictive. Imagine a patch of Nassella tussock that lies partly inside and partly outside a buffer. This patch is relevant to your analysis, but the buffer does not contain it; it only intersects it. On the other hand, if a patch lies entirely inside a buffer, the buffer both contains and intersects it. Therefore, you should use the intersect relationship.
You can click the tool's View Help button to open its help topic. In the help topic, the Summary and Usage sections give general information about the tool. The Syntax section describes its parameters. See Anatomy of a tool reference page to learn more about the organization of geoprocessing tool help topics. See Select By Location graphic examples for illustrations of how spatial relationships are defined with respect to different feature types (points, lines, and polygons).
- On the Select By Location tool, confirm that the Input Features parameter defaults to Campground_Buffers and that the Relationship parameter is set to Intersect.
- Click the Selecting Features drop-down arrow and click Nassella Tussock Range.
The features in the input feature layer are the ones that will be selected. You want to see which campground buffers are intersected by grass, not which patches of grass are intersected by campground buffers.
There is no output feature class parameter because the Select By Location tool does not create a new dataset—it makes a selection on the input feature layer.
- Click OK.
Four buffers are selected on the map. The number is confirmed by the message at the bottom of the map view.
Two of the selected buffers are in areas where Nassella tussock is prevalent and two are not. This raises the question whether the four selected buffers have a geographic relationship that sets them apart from the others.
- In the Contents pane, turn on the Roads layer and expand it.
The four selected buffers are linked by principal highways. This suggests that the road network facilitates the spread of Nassella tussock. On the other hand, many unselected buffers are also linked by highways.
It would be useful to know which campgrounds are visited most often and whether vacationers typically visit multiple campgrounds, but these questions are beyond the scope of this tutorial.
- Turn off the Roads layer and turn on the Populated Places layer.
Three of the four selected buffers intersect populated places. At the same time, many populated places have no Nassella tussock near them. While this brief investigation was inconclusive, spatial selections are a good way to discover patterns in your data and stimulate further analysis.
- Turn off the Populated Places layer.
- On the Quick Access Toolbar, click Save .
Quantify Nassella tussock within buffers
Finally, you want to find out how much Nassella tussock lies within the selected buffers. This information can be shared with campgrounds and may help prioritize treatment. The measurements can also serve as a baseline for comparison in coming years.
The tool you'll use is Summarize Within. You'll open this tool from the Analysis gallery. The Analysis gallery is a convenient place to access frequently used analysis tools.
- On the ribbon, click the Analysis tab.
- In the Tools group, expand the Analysis gallery.
Depending on the size of your ArcGIS Pro window, the Analysis gallery may appear as a button on the ribbon.
- Under Summarize Data, hover over the Summarize Within tool and read its description.
One of the functions of this tool is to calculate how much area in polygons from one layer falls within polygons from another layer. This is what you want to do.
You can customize the Analysis gallery.
- In the Analysis gallery, click Summarize Within to open the tool in the Geoprocessing pane.
- Click the Input Polygons drop-down arrow and click Campground_Buffers.
When there is a selection on the input layer, geoprocessing tools work on the selected features only. In this case, only the four selected campground buffers will be processed and written to the output feature class.
- Click the Input Summary Features drop-down arrow and click Nassella Tussock Range.
- For Output Feature Class, change the name to Tussock_Within_Buffers.
Like the Buffer tool, the Summarize Within tool creates a feature class. The output features will have the same shapes as the input features. The only difference will be in the attribute table.
- Click the Shape Unit drop-down arrow and click Hectares.
A hectare is a metric unit of area equal to 10,000 square meters or roughly two and a half acres.
- Click Run .
When the tool completes, the Tussock_Within_Buffers feature class is created in your project geodatabase and a layer is added to your map.
- On the ribbon, click the Map tab. In the Selection group, click Clear .
- In the Contents pane, turn off the Campground_Buffers layer.
The Tussock_Within_Buffers layer has four features, corresponding to the four selected campground buffers.
- In the Contents pane, right-click the Tussock_Within_Buffers layer and click Attribute Table .
- In the table, right-click the BUFF_DIST field heading and click Hide Field . Hide the ORIG_FID, Count of Polygons, Shape_Length, and Shape_Area fields also.
The Summarized area in HECTARES field shows the analysis results. Remember that the Nassella Tussock Range layer represents areas within which the plant has been found, not the actual plant density.
To display hidden fields, click the Menu button on the table view and click Show All Fields.
- Close the table.
Visualize analysis results
In this study, you have a small number of samples and it's easy to compare them in the attribute table. However, with more samples, charts are a better tool for comparisons. You'll create a bar chart of the analysis results.
- In the Contents pane, right-click the Tussock_Within_Buffers layer. Click Create Chart and click Bar Chart .
The Chart Properties pane appears. A chart view appears as well. The view is empty until you configure the Chart Properties pane.
- At the top of the Chart Properties pane, confirm that the Data tab is selected. Click the Category or Date drop-down arrow and click Name.
In the chart view, the campground names appear on the chart's x-axis. At the moment, the chart displays the count of names per campground (which is 1). You need to choose the numeric field to chart and change the aggregation setting.
- In the Chart Properties pane, under Numeric field(s), click Select and check the Summarized area in HECTARES check box. Click Apply.
- Under Aggregation, click the drop-down arrow and click <none>.
Aggregation is only necessary when values in the category you are charting are represented by multiple records in the layer attribute table. In this case, each campground name corresponds to a single record in the table. Learn more about aggregating category values.
The chart's y-axis and data bars update to show the area covered by Nassella tussock near each campground.
- At the top of the Chart Properties pane, click the General tab. (If you don't see it, click More and click General in the drop-down list.)
- In the Chart title box, replace the current title with Nassella Tussock Near Commercial Campgrounds and press the Enter key.
The title is updated on the chart.
- In the X axis title box, replace the current title with Campground Name and press the Enter key.
- In the Y axis title box, replace the current title with Range of plant in hectares and press the Enter key.
- If necessary, maximize the ArcGIS Pro window or undock the chart view and resize it to see the chart better.
By default, the data markers match the symbology of the Tussock_Within_Buffers layer. The outline symbol is useful on the map but doesn't look good on the chart.
- In the Chart Properties pane, click the Series tab. In the table of fields, in the Symbol column, click the symbol to open the color palette. On the palette, click a color that you like.
The color of the data markers is updated on the chart. Notice, however, that the campground names are cut off. This is because x-axis labels are limited to 11 characters by default.
- On the Chart Properties pane, click the Axes tab. Under X-axis, change the Label character limit setting to 30 and press the Enter key.
The full name of each campground is displayed.
- In the Chart Properties pane, click the Data tab. At the bottom of the pane, under Data Labels, check the Label bars check box.
The bars are labeled with their exact values, but you don't need to show so many decimal places.
- At the top of the pane, click the Axes tab. Under Number Format, click Determine display formatting for numeric field types .
- In the window that appears, click the Category drop-down arrow and click Numeric. Under Rounding, change the number of decimal places to 2.
- Click Apply.
- Resize the chart if necessary.
- Close the chart view.
To access the chart later, in the Contents pane, expand the Tussock_Within_Buffers layer. Under Charts, right-click the chart and click Open .
- On the Quick Access Toolbar, click Save .
View geoprocessing history
ArcGIS Pro saves a record of the geoprocessing tools you use in a project. This geoprocessing history shows the order in which tools were run and saves the tool parameter settings. The geoprocessing history can help you retrace your steps, run tools with different settings to explore alternative outcomes, and modify the workflow. You can also use the history to help build a geoprocessing model or to create a geoprocessing package of tools and data to share with others.
- On the ribbon, click the Analysis tab. In the Geoprocessing group, click History .
The History pane appears. Under the Geoprocessing tab, the Tool History tab shows the geoprocessing tools you have run. The green check marks show that the tools ran successfully.
In this analysis, you only used geoprocessing tools. If you had run any raster functions, you could see those history items on the Raster Functions tab.
- In the History pane, right-click the Buffer tool and click View Details.
A window shows the parameter settings, environment settings, and other information. If there were error or warning messages associated with the tool, they would also appear here. (The same information can be viewed on a tool's completion message in the Geoprocessing pane.)
- Close the message window.
You can also right-click the tool to open it, run it, or save it as a Python script.
Different analysis tools can sometimes be used to achieve the same results. In this case, it wasn't strictly necessary to use Select By Location. You could have run Summarize Within directly on the campground buffers. (Your output feature class would have had 14 records instead of four. Ten records would have had values of 0 in the Summarized area in HECTARES field.) One advantage of the Select By Location tool is that it provides visual feedback that can reveal spatial patterns and suggest new directions for your analysis.
To go a step further, you could have replaced the Buffer and Summarize Within tools with Summarize Nearby, which combines the functionality of those two tools. Ultimately, this means you could have obtained your analysis results using one tool instead of three. However, you might have had a less clear understanding of the stages of the analysis.
To see how the workflow in this tutorial can be modeled and run as a geoprocessing tool, try the Make a geoprocessing model tutorial.