Lab 7: Data Vector Spatial Analysis

Geography 387 – Fall 2011 Lab 7 Vector Spatial Analysis Lab 7: Data Vector Spatial Analysis 1.0 Introduction This lab will introduce vector spatial...
Author: Brittney Mills
1 downloads 3 Views 2MB Size
Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

Lab 7: Data Vector Spatial Analysis 1.0 Introduction This lab will introduce vector spatial analysis functions found in ArcMap. In particular, we will learn about selecting based on location, buffers, and overlay. We will use a variety of scenarios and datasets to illustrate these concepts.

2.0 Download data Before we begin, download the lab7.zip data archive into your Lab 7 folder on your USB thumb drive, or local computer C drive. Unzip the archive. You should have a lab7 folder with 4 sub-folders, one for each part of this lab.

3.0 Selecting nearby features When you analyze the relationships between map features, you might need to know which features are within a certain distance of other features (proximity) or share the same boundary (adjacency). The Scenario: Suppose you are interested in buying a gas station near Interstate 40 in Old Town, Albuquerque, New Mexico. One of your requirements is that it must be within 1,000 feet of the interstate so you can attract as many drivers as possible. Start ArcMap and open the map document lab7_part1.mxd in the lab7_part1 folder. When the map document opens, you will see a gas stations layer, a streets layer, a business layer, and a zoning layer. These are all geodatabase feature classes. Set the default geodatabase to the lab7_part1.gdb in the lab7_part1 folder from the File  Map Document Properties window, and make sure that the box is checked to “Store relative pathnames to datasources”. If needed, use the Full Extent button to zoom to and center the data in the map window. The I-40 freeway is selected (shown in light blue, also called cyan) in the streets layer. You will use this feature to select gas stations within 1,000 feet. See the screenshot below. Note: If you need to reselect the I-40 freeway features, use Select by Attributes from the streets layer Table Options, and select "STR" = 'I40' (there should be 30 selected features).

1

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

Go to the Selection menu, Select by Location. The Select by Location tool lets you do simple GIS selection analysis. Keep in mind that the window provides a multitude of criteria that form a single “selection sentence.” I will provide you with the criteria for now, but later, you will have to try some of these criteria on your own. Enter the criteria as shown on the screenshot below:

2

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

This tool will select features from gas stations that are within a distance of 1,000 feet of the selected streets. Read the criteria from top to bottom so that you understand the logic in this spatial query. Click OK when all your criteria are entered. Close the Select by Location window. Question 1: (4) a. How many gas stations were selected? Hint: Gas stations are point features and the selected set is in light blue (cyan). (2) b. What are the names of the selected gas stations? Hint: use the identify tool or look in the attribute table. (2) Unfortunately, neither of these two gas stations is for sale. You would like to make a tempting purchase offer, but first you must know the market potential for each station. Because you want to sell gasoline to business customers and employees as well as freeway travelers on I-40, you decide to find out which gas station is closer to more businesses. Go to the Selection menu, and scroll to Select by Location. Enter the selection criteria as shown on the screenshot below:

Be sure to uncheck STATIONS in the Target layer part of the window. You want to select features from businesses that are within a distance of 1,320 feet (1/4 mile) from the 3

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

selected features of gas stations. Notice that the check box next to "Use selected features" is checked, indicating that we are only going to consider the distance from selected gas stations (Stations). It tells you how many features are selected, although I blurred this out in the screen shot above. Also understand that I arbitrarily chose 1/4 of a mile as a buffer distance, but you could have put at 1 mile, 1 km, etc. by changing the buffer distance parameters. Note that the box next to “Apply a search distance” is checked. Click OK when all your criteria are entered as above. To see which business were selected and examine their attributes, open the Attribute Table for business. Notice that many of the businesses have the same address, indicating that they are located in a shopping center. Also note that your selected gas station points (from Question #1) also show up in the selection in the business layer. This is because the gas station layer was originally created by selecting gas stations from the business layer. For the question below, count the number of business points near each selected gas station by using the Identify tool . When you click on a highlighted business point with this tool, you will see in the results all of the businesses at that location. If you hold down the control key as you click on additional business points, they will be added to the existing list of businesses in the Identify window. You can then view the attributes for any of your business points by clicking it in the Identify window. Note: You can also identify multiple features with the Identify tool by holding down the left mouse button and drawing a box around the features that you want to identify. Select the business layer in the “Identify from:” drop-down box on the Identify window to use this option. Question 2: (4) a. Based on this selection of businesses, which of the gas stations you identified in Question #1 do you think would service more customers? (2) b. How many businesses are there around this gas station within 1/4 of a mile? (2) ArcMap can also find features adjacent to selected features. To see how this works, consider a situation involving parcels of land. The Scenario: Suppose that Old Town is planning major improvements to its drainage system. Municipal planners need answers to these questions: 1) which parcels include or are adjacent to drainage ditches?; 2) how many of these parcels are in the city’s jurisdiction and how many in the county’s jurisdiction?; and, 3) what is the total acreage of parcels by jurisdiction? Turn off all the layers in the table of contents (TOC) and turn on the Zoning layer. Notice that drainage ditch polygons are already selected for you (cyan color). First, we’ll find out which parcels are adjacent to drainage ditches. 4

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

Note: If you need to reselect drainage ditch polygons, use Select by Attributes from the zoning layer Table Options, and select "DESCRIPTIO " = 'DRAIN' (there should be 9 selected features).

You want to select features from the zoning layer that touch the boundaries of the selected features in the zoning layer (i.e., drainage ditches). Note that you have to change the “Spatial selection method” from its default value. Click OK when all your criteria are entered. To see which parcels were selected, open the Attribute Table for the zoning layer. Question 3: (2) How many parcels (including the ‘DRAIN’ features) will be affected by the drainage ditch improvement project? Now we need to determine the total acreage of these selected parcels by jurisdiction. In the Attribute table of the zoning layer, right click on the Jurisdiction field (it is called JURIDICTI) and select to Summarize. Enter the options exactly as you see them in the screenshot below. Be sure to select the check box to summarize the selected records. Save the output table in your lab7_part1.gdb geodatabase as “jurisdiction_acreage”.

5

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

Do you see what this Summarize selection will do for you? Click OK when all your criteria are entered. Click Yes to add the table to the map document. Open the table to answer the following questions: Question 4: (4) a. How many city acres will be affected by the improvement project? (2) b. How many county acres will be affected by the improvement project? (2) Congratulations on your spatial analysis -- now Old Town will know how much city and county land the new drainage improvement program will affect.

4.0 Selecting features within The Select By Location tool also allows us to select features that fall completely within a polygon. Conversely, you can find polygons in one layer that contain particular points, lines, or polygons in another layer. This type of spatial relationship, features inside of other features, is known as containment. Finding out where a feature is inside or outside a boundary can be crucial to making decisions. The Scenario: Your company is transferring you to the Atlanta region, and you would like to purchase a home after you get there. Before you call a real estate agent, you would like to become familiar with the region yourself, and possibly even identify some areas you might like to live in. You are primarily interested in areas where population is low compared to the rest of the region, and more importantly, in areas where your thirteen year-old daughter can attend middle school close to home. Open the map document lab7_part2.mxd in the lab7_part2 folder. We are done with lab7_part1.mxd; you can save changes if you want (optional). When the lab7_part2.mxd 6

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

opens, you will see Middle Schools, Counties, and Census tracts layers. Set the default geodatabase to the lab7_part2.gdb in the lab7_part2 folder from the File  Map Document Properties window, and make sure that the box is checked to “Store relative pathnames to data sources”. If needed, use the Full Extent button to zoom to and center the data in the map window. See the screenshot below.

First, we will find areas that have a low population density. We will search for areas that have population less than the mean population for the area. We will use 1990 population attribute data in the Census tracts layer to do this analysis. Open the attribute table for Census tracts and calculate the statistics for 1990 population (“POP_90” field). Make a note of the mean population value. Now go to the Selection menu, and pick Select by Attribute. Remember this tool? You may have only used this tool from the attribute table of a layer, but it is also available from the Selection menu. Enter the appropriate selection based on the criteria stated above, applied to the Census tracts layer (i.e., find Census tracts polygons with a 1990 population less than the mean population). Click Apply when you are done and close this screen to view your selection. See the screenshot below.

7

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

By looking at the map view, you can see that some of the highlighted census tracts have middle schools. You want to find census tracts that have low population and middle schools. Since the census tracts and middle schools are in separate layers, we need to use a layer-on-layer selection to find census tracts that meet both of your criteria.

8

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

Go to the Selection menu, Select by Location. Enter the criteria as follows:

You are selecting features from the currently selected features in the Census tracts layer that completely contain the features of Middle Schools. Read through the criteria from top to bottom to make sure understand the selection statement. Click Apply when you are done and close this screen to view your selection. You should see census tracts that meet both your criteria -- low population and contain a middle school (see screenshot below).

9

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

The Scenario: Now you have just learned from a future coworker in the Atlanta region that property taxes are lower in Cobb County than in other counties in the region. As a bonus, you also learn that your future boss lives there, too! You now need to find out which of the selected census tracts fall within the Cobb County to help narrow your search for a home. Turn off the Middle schools and Census tracts layers in the TOC. Open the attributes table for Counties and select Cobb County. Hint: you can build a query or just click the row in the attribute table that has Cobb County. Close the attribute table and notice that the Cobb County polygon is selected in the map (cyan color).

10

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

Now turn on all the layers in the TOC again. Go to the Selection menu, and pick Select by Location. Enter the selection criteria as shown in the screenshot below:

This tells ArcMap to select from the currently selected features in Census tracts only those polygons that are completely within the selected features of Counties (i.e. Cobb County). Click OK when you are done. Question 5: (3) a. How many census tracts were in your final result? (1) b. What is the mean per capita income (PER_CAPINC) for your selected set? (2)

5.0 Buffering features Buffering and overlay are two of the most common operations in spatial analysis. A buffer zone is an area that is within a given distance from a map feature. Points, lines, or polygons can be buffered. Buffers are used to identify areas surrounding geographic features. For example, you may wish to keep septic systems over 100 meters away from streams, locate housing within a quarter mile of existing roads, keep hiking trails away from seasonally-flooded rivers, or make sure most of your city is within some maximum distance from a fire station or school. When you buffer on a set of features, the output is a set of polygons (buffering points or lines creates a new layer that contains polygon geometry). These polygons define an inside region, an area less than the specified buffer distance from the features of interest (e.g., less than 300 meters from a stream), and an outside region, an area more than the specified buffer distance from the features of 11

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

interest. The figure below shows streams buffered at 300 meters. Be sure that you understand what areas are inside of the buffer zone and what areas are outside of the buffer zone.

Sometimes when you buffer a stream network with a large buffer distance, the buffers from different streams intersect and you get enclosed polygons (see figure above). These areas are still more than the specified buffer distance from the stream (they are outside of the buffer zone), but are isolated because you must cross a buffer zone to get to them. Some GIS software programs identify these areas as being different from areas which are totally outside the requested buffer. The Scenario: Vernal pools are seasonal wetlands in shallow depressions that fill during the rainy season and persist for several months before drying up in the summer. Some rare and specialized plant and animal species, known as “vernal pool endemics”, are completely dependent on these ephemeral pools. Once more widespread, much of this habitat has been lost due to development. Most of the remaining vernal pools in Sonoma County are found on the Santa Rosa Plain. (Community Foundation Sonoma County, 2010, Section 2, pp. 10-11. Biodiversity Action Plan: Priority Actions to Preserve Biodiversity in Sonoma County. Retrieved Nov. 4, 2011 from http://www.sonomalandtrust.org/pdf/Biodiversity_Action_Plan_2010_reduced.pdf) Additional information: A two page document from the City of Santa Rosa about vernal pools on the Santa Rosa Plain that includes pictures of some of the special status species can be downloaded from: http://ci.santa-rosa.ca.us/doclib/documents/VernalPool.pdf Scenario: The County of Sonoma has contracted you to identify and make a map of parcels that are located within 2000 feet of active vernal pools, so that the parcel owners can be notified of special permit requirements for new projects. The area of interest is located in a portion of unincorporated Sonoma County west of Hwy 101 between Santa

12

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

Rosa and Rohnert Park. The county has provided you with GIS layers of parcels point locations of the vernal pools in this area. Data disclaimer: The point locations of vernal pools used for this lab assignment are hypothetical, and do not represent actual pools. The points are, however, located within areas that have been identified by the California Dept. of Fish and Game as “vernal pool complexes” that are at least 40 acres in size. We will use buffers and Select by Location to make this map. Open the map document lab7_part3.mxd in the lab7_part3 folder. You do not need to save lab7_part2.mxd. Set the default geodatabase to lab7_part3.gdb, and make sure that the box is checked to “Store relative pathnames to data sources”.

First, we will make a 2,000 foot radius buffer around the vernal pools. Open the ArcToolbox window and navigate to Analysis Tools  Proximity  Buffer. (Alternatively, you can find Buffer, and several other commonly used tools, under the Geoprocessing menu on the standard toolbar.) Select vernal pools as the input feature and choose an appropriate name for the output polygon feature class (store the output in lab7_part3.gdb). Enter in 2000 feet for the buffer distance. Select ALL in Dissolve Type to dissolve all the buffers together into one output feature and remove overlapping features. You can expand the help window with Show Help >> and then click in any parameter window to see what the different options mean. This is particularly helpful when buffering lines and polygons, as there are more options available. See the screenshot below.

13

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

Click OK to run the buffer tool. Turn on the output vernal pool buffer in the TOC.

This gives us circular zones around vernal pools. We will need this buffer feature class for our final map. We now need to select those parcels that are within these zones. We can do 14

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

this with Select by Location. As with many GIS tasks, there are different options for doing this. One option is to select parcels that "are within a distance of” vernal pools, and set the distance at 2000 feet. See example of this selection below.

However, there is an equivalent way, and this will allow you to learn another selection type called “intersect”. When features share the same geographic space, they overlap, or intersect. ArcMap can find features that intersect, whether they are in the same layer or in different layers. Using layer-on-layer selection, you can find and select features that intersect other features in another layer. Here we can select parcels (polygons) that intersect the vernal buffer polygons (2000 radius polygons around vernal pools). The results are the same as using the "within distance of" method in Select by Location, shown above. See the screenshot below.

15

Geography 387 – Fall 2011

Lab 7

Click OK.

16

Vector Spatial Analysis

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

Your selected parcels should look like the screenshot above. Notice that some parcels go beyond the bounds of the buffer zones. This is because only a portion of any given parcel must intersect the buffer zone for it to be selected. This is what we want in this case, since the county wants to notify parcel owners if any portion of the parcel is within 2000 feet of a vernal pool. Let's export the selected set of parcels that intersect the vernal pool buffers to a new feature class. Right-click on parcels, and navigate to Data  Export Data. Give your output parcels a meaningful name and save to the lab7_part3.gdb geodatabase in the lab7_part3 folder. Note that we could have selected only those parcels that are completely within the buffer zones by modifying the query once again, using the “Target layer(s) are completely within the Source layer feature" option in Select by Location. You can now clear the selected parcels. Do this by going to Selection, then Clear Selected Features. Save the map document. Map 1 (10) Make a map of the parcels that intersect the 2000 ft buffers around the vernal pools. The map should be in gray-scale colors to reduce costs of printing the map to distribute to parcel owners. Include the 2,000-foot radius buffer circles around the vernal pools (hint: make the fill transparent). The selected parcels that intersect the vernal pools should be dark gray, and all other parcels should be light gray. Include a scalebar, title, name, legend, etc. Export the map to a PDF file with 150 dpi.

6.0 Overlaying layers Overlays are another common analytical operation. They are the primary way in which information from two separate layers may be brought together in an analysis. Overlays are most common for polygon data. A geometric intersection of 2 polygon layers results in a new layer with the combined attributes of both input layers. For example, suppose we wish to identify all the areas in a given county that are also forested. We might have a counties layer and a forest layer, both with polygons. If we overlay these two layers, we will have a single output layer that has both county and forest cover information. By selecting only those polygons that are both in a desired county and that are forested, we will identify the forested portion of the desired county. The Scenario: This final lab exercise will use roads and water layers to find potential campgrounds sites for the Desoto National Forest, in southern Mississippi. The campground will have ‘drive in’ sites, which must be within a buffer zone around roads. The final map will show locations that are both within 150 meters of a lake or 500 metersof a river and within 300 meters of a road.

17

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

Open a new map document in ArcMap. Set the default geodatabase to the lab7_part4.gdb in the lab7_part4 folder. Load the Roads line feature class and the Water polygon feature class from the lab7_part4.gdb. Use the buffer tool to make a 300 meter buffer around the roads. For buffer parameters, use Side Type "FULL", End Type "ROUND" and Dissolve Type "ALL". Remember, you can use the help window and click in the parameter windows to learn more about these options. Give your output roads buffer feature class an appropriate name, and output it to lab7_part4.gdb.

Open the Water feature class attribute table. Note that there is a column called Buff_Dist that has 150 coded for Lake polygons and 500 coded for the River polygon. We will use this field to produce a variable-distance buffer. Again go to the buffer tool and select Water for the input feature. This time chose the Field option instead of a fixed distance. For the field, chose Buff_Dist. This will make the buffer distance around each Water polygon to be defined by the value in the Buff_Dist field.

18

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

Click OK to run the buffer. Notice that the lakes and rivers have different buffer sizes.

We are now going to overlay the variable-distance Water buffer and the fixed-distance Roads buffer. To overlay them, we need to do a few things. 19

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

When overlaying layers you must set up the two files in a manner that allows the results to show from which input layer a particular feature originated. To do this, add a field to the water buffer layer, call it “inside_waterbuf”, and calculate a value of 1 for the water buffer polygons (you should know how to do this by now without step-by-step instructions). Do the same for the road buffer layer. Add a new attribute called “inside_roadbuf” and assign it a value of 1 to indicate it is inside the road buffer polygon. You may ask why we don’t assign the outside a value, too? Right now, there are no features outside our water or road buffers. We can’t assign values without an underlying feature. The Overlay toolset in Analysis Tools in ArcToolbox contains tools to overlay multiple feature classes. Options are to combine, erase, modify, or update spatial features in a new feature class. New information is created when overlaying one set of features with another. There are seven types of overlay operations; all involve joining two or more existing feature classes into a single feature class, allowing us to identify spatial relationships between the input features. The following table lists the tools available in the Overlay toolset and provides a brief description of each.

Tool

Description

Erase

This tool creates a feature class from those features or portions of features outside the erase feature class.

Identity

This tool combines the portions of features that overlap the identity features to create a new feature class.

Intersect

This tool builds a new feature class from the intersecting features common in both feature classes

20

Geography 387 – Fall 2011

Spatial Join Symmetrical Difference

Lab 7

Vector Spatial Analysis

This tool builds a new feature class by joining attributes from one feature class to another based on a spatial relationship This tool creates a feature class from those features or portions of features that are not common to any of the other inputs.

Union

This tool builds a new feature class by combining the features and attributes of each feature class.

Update

This tool updates the attributes and geometry of an input feature class or layer by the Update feature class or layer that they overlap.

The final step of this section is to overlay our two buffer layers. Go to ArcToolbox again and navigate to Analysis Tools  Overlay  Union. Enter the following criteria, and remember that you can drag and drop layers into the Features list from the TOC. Be sure that the box is checked next to “Gaps Allowed”. See the screenshot below.

21

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

Click OK. Display the new Union layer and open its attribute table. Your output should look similar to the screenshot below.

22

Geography 387 – Fall 2011

Lab 7

Vector Spatial Analysis

Question 6: (3) a. How many records are there in the Union layer? (1) b. Why do you think you have more records than in your input buffer layers? (2) Use Select by Attributes on the Union layer to find those areas that are BOTH within the roads buffer and the water buffer (hint: this is where inside_waterbuf and inside_roadbuf both have a value of 1). Export your selected polygons to a new feature class in lab7_part4.gdb, called acceptable_sites. Map 2 (10) Create a map of the acceptable camping sites (acceptable_sites). Include roads and water features, but not their buffer layers. Include a scalebar, title, name, date, legend, etc. If you want a background layer of the extent of the study area, you can add the study feature class. Optional: You can also add background imagery or other layers by clicking the side pop-up menu next to the Add Data button, then go to Add Basemap.

7.0 Conclusions You now have first-hand experience with the basic tools that you need for vector spatial analysis. We have not shown you all the tools available. For example, the overlay tools intersect, identity, update were not covered. It is up to you to explore these tools and their many parameters. The datasets from this and previous labs are relatively small and make great layers for experimenting with the outputs from various analytical tools. Always remember to use the ArcGIS Desktop Help to get a more detailed explanation. Have fun exploring!

8.0 To turn in ● ● ●

Your answers to the 6 questions in a Word document (20) Map 1 (pdf format) (10) Map 2 (pdf format) (10) Submit electronic files via email to your instructor, subject "G387, Lab 7, [your last name]". Credits: This lab was designed by Matthew Clark, Geography and Global Studies Department, Sonoma State University. Data layers and much of the text for Sections 3, 4 and 6 were modified from materials provided by Paul Bolstad (Univ. of Minnesota) and George Raber (Univ. of Southern Mississippi). Edited for ArcGIS 10 by Elizabeth Lotz. 23