Part III Student Handout
Introduction to ArcGIS 10 ModelBuilder
The project study area is in San Bernardino County, California, which has been prone to mudflows and landslides due to several factors. It is also an area that has been affected by wildfires – the most recent of which occurred in October 2003. For additional background, refer to Part I. This Part III of the study uses real-world data and methods to look at some possible analysis models using ModelBuilder to determine landside susceptibility including slope, aspect, vegetation and other possible factors. You may want to go to ArcGIS Desktop Help and search on Model Builder. You can also look at A Quick Tour of ModelBuilder to learn more about it.
This is a continuation of from Part II and uses the ArcGIS project created in Part II named Landslides. If you have not done the project in Part II, you can use the project in Part I (SB_Geology_V1). You should review the introductory section on Slope, Aspect and Vegetation in Part II. Part III also assumes you have learned the basic techniques so that every Step is not specifically given. If you do know how to do a Step, return to Parts I and II or use ArcGIS Desktop Help.
Creating a ModelBuilder Model to Automate the Analysis
ModelBuilder creates a flow process diagram that contains all of the input data, functions and output data that you manually created using ArcToolbox and Tools individually in Part II. Creating a model for your project gives you the ability to: (1) share the model with other users, (2) use the same model in other regions with their elevation data sets, (3) repeat reclassifications with different values to see how those values affect which regions may be susceptible to landslides and use these to verify field results, and (4) embed your model in other more complex models.
Step 1: Open your Landslides project from Part II (or SB_Geology__V1). (Note: this part of the study assumes that you know how to do basic steps and the location of data and projects. If not, please refer to earlier parts or use Help.)
q Use Save As under the File menu, name the new project SB_Geology_MB and be sure it is saved in C:\ArcProjects\SB_CA_Geo\Geodatabase\SanBern.gdb. (How do you know you know are working on a new project? Hint – title bar.)
q For most projects, you should always start by being sure that your preferences are set – this includes setting the Map Document Properties, the Environmental Variables and Map Options. Follow the steps below for your SB_Geology_MB Project:
o Under File menu > Map Document Properties, fill in the details for new Title (SB_Geology_MB) and be sure to set the “Default Geodatabase to: C:\ArcProjects\SB_CA_Geo\Geodatabase\SanBern.gdb and check the “Store relative pathnames to data sources” then click OK.
o Go to the Geoprocessing menu and select Environment. In the Environmental Settings select Workspace. For Current and Scratch Workspace browse to C:\ArcProjects\SB_CA_Geo\Geodatabase\SanBern.gdb then click OK.
o Go to the Geoprocessing menu and select Geoprocessing Options and be sure that “Overwrite the Output of geoprocessing operations” is checked.
o Under “Customize” menu under Raster tab and “Raster Dataset” be sure that “use world file to define coordinates of rasters” is checked.
Part 3 of a five-part tutorial created by the Integrated Geospatial Education and Technology Training (iGETT) project with funding from the National Science Foundation (NSFDUE-0703185) to the National Council for Geographic Education. Available for educational use only. See http://delmar.igett.edu for additional remote sensing exercises and other teaching materials. Opinions expressed are those of the author and are not endorsed by the NSF. 1/15/2012
Under Customize menu > Extensions be sure that Spatial and 3D are checked and then close dialog box.
q Create a new Model by using the Geoprocessing menu and selecting ModelBuilder. To learn more about Model Builder click on Help and select ArcGIS Desktop. The ModelBuilder Window and tools include:
q Click on Model menu and Model Properties and name and label it Landslides. Check “Store relative path names” and click OK.
ModelBuilder models are saved in your geodatabase (SanBerm.gdb) but you must first create a Toolbox for them to be stored in.
q Under the Model menu, click Save. This will open the Save window – be sure “Look In” box is at the SanBern.gdb. Click on the Toolbox on the far right of the menu. A Toolbox is added. Click on it and rename it LandslidesMB. Click your new LandslidesMB toolbox, and it will move into the “Look in:” area. Them in Name box the name Landslides should have appeared automatically. Click Save. Close the ModelBuilder Window.
q Using the Catalog window, go to the SanBern.gdb and expand it until you see your new LandslidesMB toolbox and the Landslides model. Right click and click on Edit. The Landslides model should open.
q Position the ArcMap window (click on the blue title bar) so that you can see the Table of Contents of ArcMap and the Model window. You can also resize the Model window to make it larger (hover over a corner and click/drag).
q Click on the sb_dem and drag, and drop the sb_dem grid onto the Model window. If you get an Error message, you can use the Add Data button and add it from the C:\ArcProjects\SB_CA_Geo\Geodatabase\SanBern.gdb folder.
You will now add “tools” from ArcToolbox window, so “pin” it open.
First expand the Spatial Analyst Tools and Surface toolsets.
q Click and drag each tool for Hillshade, Slope and Aspect tools onto the Model. Don’t worry about placement of these tools, as we will clean that up below.
q Use the connect tool to draw (click on data oval and drag to function rectangle) and create an arrow between the input data set and each of the functions (ovals for Slope, Aspect and Hillshade) and click on “input raster” for each tool.
SAVE BOTH your Model And the Project OFTEN!
The input data sets are blue ovals. Functions are rectangles that turn yellow when connected and have output determined. Output data sets are ovals that turn green when they are connected to functions and have output determined. If they remain clear, you may need to click on the output oval and set the output location and name of the dataset.
q Right-click on each of the output ovals and select Rename and type in a name for each that is appropriate (sb_slope2, sb_aspect2, sb_hlshd2).
q Click on the auto layout button and the tools will be relocated to better positions. You may also need to “enlarge” the output green ovals to fit the names.
q From the Catalog window expand to locate Sb_burn_serverity feature dataset from LocalU11N27 and drag it on to the Model.
q Next, using the Conversion Tools in the ArcToolbox drag the Feature to Raster tool from the To Raster toolset onto the Model.
q Use the connect tool to connect the Sb_burn_severity feature dataset to the Feature to Raster tool and input.
q Double-click on the Feature to Raster function rectangle and it will open a dialog box.
q For field choose VEGBURNSEV and change output name to sb_burn_sev2 and change 3.
q Click on the tool to automatically arrange the model features. (Note that you can zoom in and out or change viewing area as needed.)
q If you want to see the output dataset of any of the functions in your ArcMap document, right-click on the output oval and select Add to Display. At a minimum, you should display the sb_hillshade.
q Run the model (menu Model > Run).
Note: The ovals and rectangles will become “shaded” as the model runs. The “process” functions turn red as the model is run. The model process window will let you know what is happening in the model and if there are errors. Note: if you Run this or have created the same data, you must remember to allow datasets to be overwritten. If you have not set this using Geoprocessing Option to allow Overwrite the outputs of geoprocessing options you will get an error.
q Once the Run has been executed, you must close the dialogue box in order to access the model or other documents. You can check the radio button on this dialog window so that it will automatically close if the analysis was successful.
Now you will Reclass the sb_slope2 and sb_aspect2 using the Reclassify tool in the Reclass Toolset in the Spatial Analyst toolbox.
q Drag and drop the Reclassify tool from the ArcToolbox window onto the model twice (once for slope and once for aspect).
q Use the connect tool to connect each input raster to the sb_slope2 and sb_aspect2 output.
q Right-click on each output oval and rename appropriately. Before running you will need to set the reclassified values as you did earlier.
q Double-click on the rectangle for reclassifying the slope dataset.
q When dialogue opens, click on Precision button and set it to 0 decimal places then click OK.
q Click on Classify button and pick Natural Breaks and type in 6 classes.
q In the Break Values table (on right), highlight each value and change the values to 5, 10, 15, 25, 33, 81 and click OK.
q In the New Values field, type in the values (click enter after each entry) in the Reclassify window for each listed below:
0 – 5 / 05 – 10 / 0
10 – 15 / 1
15 – 25 / 3
25 – 33 / 6
33 – 81 / 6
q Scroll down and for the Output raster browse to C:\ArcProjects\SB_CA_Geo\Geodatabase\SanBern.gdb and name it recl_slp2.
q Click OK.
Now we will reclassify Aspect.
q First double-click on the function rectangle for reclassifying aspect.
q When dialogue opens, click on Precision button and set to 0 decimal places then click OK.
q Click on Classify button and for Method pick Defined Interval and type in 30 for the Interval Size value then click OK.
q You will now set “New Values” in the Reclassify dialog box so that Aspect values from 0 to 90 and 170 to 360 (generally northward) will have a value of 0. Values from 90 to 120 and 240 to 270 will have a value of 1 and values from 120 to 240 will have a value of 2.
-1 to 0 / 00 to 30 / 0
30 to 60 / 0
60 to 90 / 0
90 to 120 / 1
120 to 150 / 3
150 to 180 / 6
180 to 210 / 6
210 to 240 / 3
240 to 270 / 1
270 to 300 / 0
300 to 330 / 0
330 to 360 / 0
q Scroll down and for Output raster name it recl_aspt. Click OK.
q Run the model again (Model > Run).
The output of these analyses will be used as the input for the Raster Calculator tool that will include reclassified values for slope, aspect and burn severity. It will be weighted so that slope values are 60% and aspect and burn severity are 20% each of the output.
q Click and drag the Raster Calculator tool from the Map Algebra toolset from the ArcToolbox window on to the model.
q Double-click on the rectangle for Raster Calculator, and when the dialog box opens double click on the name you used for the reclassified slope. Use the keypads to add * .6 +; then double click on reclassified aspect dataset and use keypads to add * .2 +; then double click on the sb_burn_sev2 dataset and use keypads to add * .2
It will look like this:
"%Reclass_slope2%" * .6 + "%Reclass_aspt2%" * .2 + "%sb_burn_sev2%" * .6
q Browse ti SanBern.gdb and Name the output High_Sus and click and OK. It will automatically add the connector arrow.
q Run the Model (Model > Run).
You now want to find only those places that are greater the 4.8 in value. You will use the Raster Calculator tool again
q Drag and drop the Raster Calculator tool on the Model and Double-click on the function rectangle to open it.
q For the input select High_Sus and then use the keypads to add > 5 and name the output Highest2 and click OK. Run the Model
q Right Click on the output Highest and select Add to Display. Your model should look similar to the Model below (use the Auto Layout button to organize your elements in the Model).
.
q Save your Model (Model > Save). You can Export your Model as a JPG by using the Model menu and Export and Export Graphic (save in the Miscellaneous file) with an appropriate name.
Now you can reorder the data layers in the Table of Contents so that you can see the output of the Model. You can remove the 0 values for the Highest dataset (remember to right click on its name, Symbology and remove). You may want to rename some of the layers or change their size or color so that they are more descriptive or visual.
How do the ModelBuilder results compare with the manual analysis you carried out in Part II?
q Save your project. If time permits you may want to go back and change the values or percent influence and see how it changes your out.
Step 2: You will now create a new Layout with a location Map for the State of California. Instructions given here are limited so use Help for assistance.
q Uncheck datasets you do not want to appear in your map.
q Change from Map view to Layout view. Add the Layout Toolbar if it does not automatically appear. Use Insert Menu to Add Legend, North Arrow and other cartography elements.
q Double Click on the Legend and add or delete items from the Legend, depending on what you have in your Layout.
q Insert menu Picture and go to the Landslide Model and add from your Miscellaneous file. You can Add a California Boundary by Adding Data Frame and using the RegionalU11N27 and CA_State_Boundary from the SanBern.gdb.