TIME CHART FOR YOUR GEOGRAPHICAL MODEL
FOR/GGR 525


MODELING ASSIGNMENT

INTRODUCTION

Geographical (cartographical or spatial) analysis allows you to study real-world processes by developing and applying models. Such models illuminate underlying trends in the spatial data and thus make new information available. In this lab you will create a geographical model using the GIS commands you have learned thus far and the data set from flag24. Read through this entire page prior to starting work on this portion of the assignment. 

STEP 1: (Week 7-8) SETTING UP THE MODEL LOGIC
Select 4 to 7 layers to include in a model. Make a flowchart (to turn in) and design the model. Make a listing of the variables you will include and take a look at the items (in ArcCatalog), then assign these variables to the classes suitable or unsuitable (here we have used harvest and no harvest). Later, when you write your weighting and classification programs, these two suitability classes will be further divided into 5 classes: optimal, good, fair, poor, and exclude.

I chose to create a 'Harvest Suitability Model' (courtesy of D.P. Dykstra). We used four layers in this model: Natural Vegetation (pines), Slope, Geology (texture), Streams (200 m buffer).


Figure 1. Diagram of Harvest Suitability Model.


STEP 2. (Weeks 9-10) GET THE DATA

  1. Start ArcCatalog. 
  2. Navigate to your for525 folder and make a new folder called model if you don't already have one.
  3. Copy coverages you will need for your model from flag24 into your model folder using ArcCatalog.
  4. Close ArcCatalog and open Windows Explorer.  Navigate to the C:\temp directory, and create a new folder under the C:\temp directory called "your usernameggr525."  For example, mine would be "rcb28ggr525." 

    5.    Copy and paste the model folder from your Z drive into the C:\temp\"your usernameggr525" folder. You should now have a folder named model in the C:\temp\"your usernameggr525" folder that contains the coverages you need, plus another folder named info.  Remember to remove the read-only attribute from these folders.  This will allow you to save more quickly than trying to write across the network. 

Make sure you copy these data back to your Z:\ggr525\model folder when you are done with your editing session, or you will loose all of the edits you have made in this session!!!
  
6.    Open ArcMap and add the 4 or more layers with which you will be working. Try displaying several coverages at once in ArcMap, selecting the desired attributes in each layer. In effect you will see how your model might look before you actually combine them with overlay commands. 

    7.    For example, say that in our suitability model, we are interested in looking at pine, but not dwarf pines. So, we construct a query to see just the polygons we want:


    8.    Do this with each layer so that you can see how they will overlay.


STEP 3: (Week 10) PREPARE THE DATA

INTRODUCTORY INFORMATION (yes, read it).

  1. Before you combine your layers you need to buffer the selected buffer layers.
  2. Remember that any layers that are not polygon datasets will need to be buffered for overlay, for example roads or wells. Since we are doing polygon on polygon overlays, it is these final buffered cover(s) that you will use in the model.
  3. If you only want to Buffer a certain feature type (like only road CLASS = 2) then they need to be first extracted and put into another coverage using ArcToolbox/Extraction Tools/Select. Then buffer the new coverage.
  4. You DO NOT need to Select just the polygons with attributes you want from each of the other (non-buffered) layers. For example, if you only want the Forest Service land in the Owner coverage, you will only give Forest Service a weight in your model program. This essentially eliminates all the other classes from your model.
  5. In addition, if there are any other manipulations you need to do to a coverage, do it now. For example, you may want to change item names or attribute values so they meet the requirements of your model.
  1.  Buffering Review

    In Exercise 7 you completed a number of buffering processes in ArcToolbox. 

    Another way to buffer is from ArcMap, but only use ArcMap to test the result of different buffer parameters before committing to one.

    1. From ArcMap choose Tools/Buffer Wizard .
    2. Choose the desired layer to buffer and click Next.
    3. Choose the buffer type, as either a single distance from features, as multiple buffers around features, or using a feature attribute (by supplying the item name that contains the attribute). 

      The following is just an example, use the parameters appropriate for your own model.

      Pretend that in our harvest suitability model, suitability increases as we move away from archaeological sites. To model this process, we would need to create a multiple buffer that covers the entire landscape. We have to choose a buffer width (the distance between the rings), and choose the distance units. In the following example we choose enough rings to reach the edge of the landscape (indicated by the coverage outerbnd), making them 500 meters apart. You may need to use the measure tool in ArcMap on the Tools toolbar to find an effective measurement. Find the feature that will require the most buffers to reach the furthest edge. Measure the distance from that feature to the edge. Write that number down so you won't forget it. Now divide that number by the buffer width to determine how many buffers you will need. Write that number down. Scratch your nose. Don't forget to wipe and wash.



    4. In this case we want to dissolve lines between buffers and choose the output as graphics in existing layer for accuracy check before creating the final layer:






    5. If you like the way the results look, run the buffer procedure in ArcToolbox using the same parameters. From ArcMap you can only save a shapefile or layer, and we want polygon coverages for overlay.
    6. You may not want to buffer every feature in a coverage. For example, in archsites, you may want to buffer only Anasazi sites, or only Hohokam sites or both. One way to do this is to:

      1. In ArcCatalog add a field called BUFFVAL. In ArcMap, double-click the desired layer (or right-mouse-click the layer and choose Properties).
      2. Now you will have to calculate a field value for buffer distance. 
      3. Now, in ArcMap use the Definition Query tab, choose Query Builder... and select only the features which you desire to buffer.
        Start editing, open the archsites point attribute table, choose Options/Select by Attribute.
      4. In the query window, find type "NAME" = 'Anasazi*'.



      5. Then right mouse-click buffval, choose Calculate Values, choose Yes to turn off redo/undo functions, and set the value to, in this case, 1000 m.



      6. Then query for Hohokam sites and set the values to 500 meters. 
      7. Calculate all other attributes to 0. 
      8. From  ArcToolbox, open the Buffer Wizard.


      9. Choose to buffer At a distance from an attribute.



      10. Name the inside item something unique to that coverage so that when you see it in the final combined attribute table, you will know from where it came. 

      11. If you get an error message that stops the buffering process, you may need to rebuild the topology of your dataset. To do this, open right-mouse click on the dataset in ArcCatalog, and choose Properties/General/arc/Topology (Preliminary) /Build. 

      12. Also, you will have problems buffering using an item if the item is named with more than one word. Don't put any spaces in the name, e.g. use BUFVAL instead of BUFFER VALUE.

      13. If you want to create multiple buffers of different sizes, use the Buffer Wizard from ArcToolbox. You can create an interesting buffer using this tool:

      14. In this case, it is advisable to calculate the inside item values equal to each buffer value:


        You can easily change the item name, if necessary, by opening the archsites dataset in ArcCatalog, double-clicking point, choosing the Items tab, highlighting the desired item and choosing Edit.

IF YOU ARE USING MORE THAN ONE BUFFERED COVER (e.g. Roads and Streams),READ THIS NOW (NOT LATER).

Look at the data table for one of your buffered layers. How does the computer know which polygons fall inside the buffer, and which fall outside the buffer? All the polygons are all part of the same layer.

The computer uses an item, or field, either named INSIDE, by default, or whatever you named it when creating the buffers. If you buffer streams and leave the default inside item name (i.e., INSIDE), and buffer roads, leaving the default inside item name (i.e., INSIDE), the inside items of both coverages will have the same name. Eventually, when all the coverages are overlaid, any items with the same name will be dropped from the joining dataset. That means that if you start with strmbuf and add roadbuf to it, roadbuf's inside item WILL BE DROPPED! Hence, THE BUFFERS WILL BE GONE!

To solve this problem, each original dataset that you are buffering needs a unique inside item name, like STRMINSD and ROADINSD.

  1. Joining Data from External Tables

Make sure all of the layers in your model have the correct codes and explanations in the attribute table; otherwise the information you want to use (which may be in an LUT - look up table - or other file) may be left out and you will have to repeat the overlay process. Therefore, in some coverages you may need to join tables together using ArcToolbox/Data Management Tools/Tables/Join Tables.

Make sure you copy these data back to your Z:\ggr525\model folder when you are done with your editing session, or you will loose all of the edits you have made in this session!!!

CONTINUE EDITING FROM HERE

STEP 4: (Week 10)    Combine your model layers using UNION and IDENTITY.

In this step, you combine all of the layers that will be included in your model using the UNION and IDENTITY commands. You have used these commands before. 
Note: All of the layers used in this step must be polygon covers. 
Also Note: If you want to use the roads or streams coverage for reference (not analysis) we will do this later when we plot the results. Everyone will start with unioning the outerbnd to their first input coverage.

Here are the steps in general:

  1. ArcToobox/Analysis Tools/Overlay/Union outerbnd to XXX to make overlay1.
  2. Next, ArcToobox/Analysis Tools/Overlay/Union overlay1 to XXX to make overlay2.
  3. Next, ArcToolbox/Analysis Tools/Overlay/Union overlay2 to XXX  to make overlay3.
  4. Next, ArcToolbox/Analysis Tools/Overlay/Identity overlay3 to XXXbuf  to make final.

...where...XXX is the name of a coverage you have chosen (e.g., landuse, geology, etc.); XXXbuf is a buffered coverage you created in Step 3; overlay1 is the overlay cover resulting from the UNION of two layers, overlay2 is the overlay cover resulting from the UNION of overlay1 and a third cover, etc...

IDENTITY, instead of UNION, is always used with buffered layers so that buffers falling outside the study area are clipped.

Do not forget that if you have more than one buffered coverage (e.g., a buffered coverage for streams and another for roads), they will both have an item called INSIDE. You must change the name of the INSIDE items (e.g., STMINSIDE or RDINSIDE) before you overlay them OR one of the INSIDEs will be dropped, removing that buffer from the final cover. Final is the name of the coverage that is a combo of all the layers and will provide your final.pat datafile. Everyone must call this final coverage "final."

Here is a specific example using 3 polygon layers (landuse, slope, geology) and 1 buffered layer (e.g., strmbuf) = 4 overlays in total. 

  1. ArcToobox/Analysis Tools/Overlay/Union outerbnd to lndowner to make overlay1.
  2. ArcToobox/Analysis Tools/Overlay/Union overlay1 to slope to make overlay2.
  3. ArcToolbox/Analysis Tools/Overlay/Union overlay2 to geology  to make overlay3.
  4. ArcToolbox/Analysis Tools/Overlay/Identity overlay3 to strmbuf  to make final.

    The output should look similar to this (if your coverage is not rectangular, talk to the instructor immediately):

STEP 5: (Week 9) Choose weight values and add your weight item (e.g., HARVEST in my case) to your final polygon.
When you produce your final polygon layer it will have many fields associated with it from all of the layers you combined but you will only be interested in certain results. You might be interested in the Pine Communities of the DESCRIP field, or the 500 value of the STRMINSD field. You want to summarize the importance of each one of these variables in a cohesive and understandable way.  To do this, you need first to decide on the importance of each variable via a "weight" between 0 and 10, or -999 if it is excluded from the model altogether. Any weights you assign to variables must be justified (i.e., results found in literature, in SCS guide, etc.). You must decide weights in this step (if you haven't done this previously). 

The weights you choose will be held in a new field that you will add to the final coverage (referred to as the weight item). So, add your weight field (e.g., ours was called HARVEST) now, which will hold the results of the weight program run - i.e., all of the weight values added together for each polygon based on each suitability type. Your weight field must be defined as follows (except for the name, which you can change):

  1. Open ArcCatalog.
  2. Navigate to your flag24/cover area and locate final polygon.
  3. Right mouse-click final polygon and choose Properties.



  4. Click the Items tab.
  5. Choose Add.
  6. Define the new item as below (you can choose your own item name).



  7. Click OK twice.

STEP 6: (Begin this step during Weeks 9-10; have it completed before Week 12) Write the weighting program.

We will use Visual Basic for Applications (VBA), which is a version of Visual Basic (VB) that runs from inside the application (in this case the application is ArcMap). VB and VBA are part of a suite of object-oriented programming languages. Chris will be talking more about VBA in class. 

  1. Copy the model.mxd document on the ACADATA drive in for525/model to your own workspace.
  2. Open the map document in ArcMap.
  3. Add just your final coverage to the map (final polygon or final2 polygon or whatever you called it).
  4. Open the VB editor using Alt+F11, or from the Tools menu through Macros. 
  5. Click the plus-sign next to the ArcMap Objects folder.
  6. Right mouse-click ThisDocument, and open the modules folder and double-click the cmdSuitabilityModel module. Examine this sample VB program provided to you.
  7. Alter the sample VB program to develop your own weighting program. Lines that begin with ', and are green are comments (the computer does not try to run this code). The program saves when you save the map, so do this often.
  8.  BEFORE YOU RUN THIS PROGRAM YOU MUST HAVE ADDED THE WEIGHT ITEM TO YOUR FINAL COVERAGE (see Step 5).

STEP 7. (Week 12) Run your weighting program.

  1. To run the program, be sure you have the final polygon layer selected in the ArcMap TOC, and you have started an editing session.
  2. Then open the VBA editor, which looks like the picture below.


  3. Click the run button or click F5.
  4. The program may take awhile to run. You'll know it is finished when your cursor goes back to normal (not an hour glass).
  5. Now switch to ArcMap and open the Attribute Table.
  6. Check the values in your weight item for accuracy. If wrong, change your program and run again.

STEP 8. (Week 12)

  1. Determine if the weighting program produced reasonable results; you should be familiar enough with ArcMap by now to know how to do this. 
  2. During the overlay process, you generated many small polygons in your final polygon layer. Some of these small polygons may meet your model criteria, but are too small to meet the Minimum Mapping Unit (MMU) of 1 hectare that I have assigned and will eventually be deleted in Step 10.
  3. Determine whether there are any areas that meet your model criteria, yet are smaller than the MMU. Determine where these small polygons are located and if they can be combined with adjacent polygons that also meet the criteria.
  4. If there are areas that meet your model criteria, are smaller than the MMU, but could be combined with an adjacent polygon and result in a polygon that meets the MMU, then you would want to keep them. Use the Dissolve command to do this. Dissolve will merge adjacent polygons which have the same value for a specified item (e.g., HARVEST). Look up "Dissolve" in Help to learn more. 
  5. From ArcToolbox, double-click the Dissolve tool in Data Management/Generalization. 



  6. Use your final coverage as input, call the output finaldis and dissolve using your HARVEST item.


 

STEP 9: (Week 12) Use ELIMINATE to get rid of those polygons less than the MMU. Everyone will use a ONE HECTARE minimum mapping unit. (Hint: 10,000 sq. meters = 1 hectare). This is to assure that your final plots are not too complex. Look up ELIMINATE in on-line help to learn more.

  1. From ArcToolbox, double-click the Eliminate tool in Analysis Tools/Overlay.



  2. Use the Query Builder to choose the small polygons.



  3. Name the output final2.


STEP 10: (Week 12) Use the FREQUENCY command to determine the range of values yielded by your weighting program. (Be sure to look for these values in your weight field.) 

  1. Looking at the values in your weight field, you will notice that there are more than 5 classes. However, since the goal of the project is to have 5 suitability classes, we will need to break the weight values into groups (classes). You will do this with the classification program in the next step. First, however, you will need to decide on how to group your data so that they fall into suitability classes of optimal, good, fair, bad, excluded (or similar types). These classes will be represented by numeric values in the class field in the final2 polygon layer. The "break points" for classes (optimal, good, etc.) may be justified from results found in the literature or can be determined by looking at the range of values. They will be different for each person's model. 
  2. If you are unable to find information in the literature about breaking your weights into classes, a helpful tool is the frequency table (like a histogram but in tabular form). The following steps explain how to run a frequency.
  1. From ArcToolbox, double-click the Frequency tool in Analysis Tools/Statistics.
  2. Use final2 polygon (will appear as final2.pat) as the input table, call the output table final.fre, choose your weight field as the frequency item and AREA as the summary item.


  3. Select the final.fre file in ArcCatalog to list the results. 


C. You can also use the different classification types in the symbol legend in ArcMap (I'll let you figure this out for yourself).

STEP 11. (Week 12 and Week 13...Have your classifying program written prior to class this week and have it run before Week 13) Add the CLASS field and write the classification program.

  1. Add the field CLASS to final2.

    When you run your classification module, it will group your weight results into suitability classes. The results have to go somewhere. They will go in the  final2 polygon layer into a field that you add called CLASS (you must use this name). The CLASS item must be added before running the program:




    Preview final2 polygon in ArcCatalog to see the new item. You will notice the item is empty (no data). 
  2. Write the classification program using the sample provided in class. Add it to the VBA editor module you inserted for the weighting program. Each sub procedure will be separated by a line as long as each procedure starts with Public Sub "name" and ends with End Sub.
  3. Run the classification program once it is ready in the same manner as you ran the weighting program. Be sure your cursor is in the correct module before choosing Run.

STEP 12: (Week 13...finish before Week 14) Conduct ONE variation of your original model.

This step is the process of generating alternative results. The ideal solution that you attempted last week may not be attainable in practice (which is not uncommon), in which case trade-offs must be made among competing objectives. An iterative process is used to develop alternatives that satisfy these objectives to different degrees or for model "sensitivity" analysis. Of course, we do not have time to develop a whole suite of alternatives, or change every variable to see how "sensitive" the model is to a certain variable, so we will only attempt one iteration.

Conduct at least one variation ("what if") of your model by using a different data layer, enlarging a buffer, and/or changing some variable weights. The more complex your iteration, the more credit you receive. The choice is yours. Be sure to keep track of the output from each change.

STEP 13: (Week 14):

Dissolve your final coverages on the CLASS field. Refer to Step 8 above.

Plot your final products (both the original model and the iteration). The plotting instructions are on the main course page under 'Plotting'. 

NOTE: To have the plots print in color, send them to the HP 2500 CM. 

STEP 14: (Week 14-15)

Write a summary report of your model. This is due on the last Friday of the semester before final's week at 4:00 pm. Instructions for page limits, and what to include in your report are included in the introduction (Time Chart for your Geographical Model). Turn the whole thing in to your Lab TA.

STEP 15: (Friday by 4:00 pm, Week 15)

Turn in the model report and have a great winter break!


Return Return to Class Home Page...