0% found this document useful (0 votes)
113 views23 pages

Finding A Suitable Site For A New School Using Model Builder2

The document provides instructions for using ArcGIS Model Builder to find a suitable site for a new school. Key steps include: 1. Converting vector data layers like land use and contours to raster for analysis in Model Builder. This includes converting contours to a TIN surface then raster. 2. Building a model in Model Builder to derive slope from elevation data, and distance rasters from recreation sites and existing schools. 3. Running the model to generate the slope, distance to recreation, and distance to schools rasters to identify suitable locations based on these factors.

Uploaded by

lahiya
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
113 views23 pages

Finding A Suitable Site For A New School Using Model Builder2

The document provides instructions for using ArcGIS Model Builder to find a suitable site for a new school. Key steps include: 1. Converting vector data layers like land use and contours to raster for analysis in Model Builder. This includes converting contours to a TIN surface then raster. 2. Building a model in Model Builder to derive slope from elevation data, and distance rasters from recreation sites and existing schools. 3. Running the model to generate the slope, distance to recreation, and distance to schools rasters to identify suitable locations based on these factors.

Uploaded by

lahiya
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 23

Finding a Suitable Site for a New School Using Model Builder

Data:

 Landuse
 Contours
 Recreation sites
 Available schools

1. Create a folder ―spatial analyst‖ in your computer hard drive (D/ or C/) and copy the data
into the new folder
2. Open ArcGIS
3. Click ―add data‖ button and browse the newly created ―spatial analyst‖ folder
4. Click ―New file geodatabase‖
5. Name new geodatabase as ―scratch‖. This is your workspace. All intermediate files and
output files will be saved in this geodatabase.

Setting workspace

1. Click the menu ―Geoprocessing‖>‖Environments‖


2. Click Workspace to expand the environment settings related to workspaces.
3. For Current Workspace, navigate to your scratch.gdb in your Spatial Analyst folder.
4. For scratch workplace again give the same Scratch.gdb in you spatial analyst folder
5. Click Ok. Now you are ready to start your analysis.

Open the 4 data layers in a new ArcMap window.

1. All layers are vector layers

Importance of each layer

Landuse: to find a suitable land for the new school


Contour: to find a flat land
Recreation sites: to find a place near to these sites
Available schools: new school should be away from available schools

ArcGIS model builder uses raster layers for the analysis. Therefore you need to convert the
vector layers into raster to perform the analysis.
From landuse layer you are going to choose a suitable landuse type for the new school. Thus you
can directly convert it to raster without further processing.

1
Landuse vector layer to raster

2. Open ArcToolbox
3. Go to ―conversion‖ tools >‖Feature to Raster‖
4. Give the details as below window and click ok

5. now you will have the landuse raster layer

Contour to raster

Similarly, you need to convert the contours to a raster layer. It needs several steps. First you must
convert the contours to a TIN surface, then to a raster surface.

Remember the contour values are in feet.

1. ArcToolbox>Analyst Tools >Data Management>TIN>Create TIN


2. Fill the dialog box as follows

2
Output TIN – Give a new name
Coordinate system – choose same coordinate system as contour layer
Input feature class – select the contour layer
Click ok. You just converted contour layer to a TIN surface

Now you need to convert the TIN layer to a Raster layer. For that,
3D Analyst Tools>Conversion>From TIN>TIN to Raster

Fill the dialog box as shown above.

Now you need to create Hillshade from the raster layer. For that,

3
Go to, Spatial Analyst Tools>Surface>Hillshade and fill the dialog box as follows

Input raster – newly created raster layer

Output raster – give a new name

Azimuth and Altitude – Keep the default values

Z factor – enter 0.3048 (since elevation is in feet, you need to convert it to meters)

Click ok

Now you have,

Landuse ( raster layer), Hillshade (raster layer), Recreation sites (vector layer),existing schools
(vector layer)

Let’s start Model builder now

You will derive slope, distance to recreation sites, and distance to existing schools,from the data
you have and then reclassify these derived datasets to a common scale from 1 to 10. You'll
weight them and the landuse dataset according to a percentage of influence and combine them to
produce a map displaying suitable locations for the new school. You'll then select the optimal
site for the new school from the alternatives.

4
1. Create a new toolbox: Goto ArcCatalog>Spatial Analyst folder>right
click>new>Toolbox
2. Name new toolbox as ―Site analysis‖
3. Then create a new model inside the Site Analysis toolbox
4. On the model's main menu, click Model > Model Properties.
5. Click the General tab.
6. Type FindSchool in the Name text box and Find location for school in the Label text
box. The name is used in scripting and at the Python Window. The label is the display
name for the model.
7. Check the Store relative path names (instead of absolute paths) check box. Checking
this box sets all source paths referenced by the tool as relative to the location of the
toolbox.
8. Do not click ok

Now you need to set the environment to perform the model accurately. For that,

9. Click environment tab

10. Expand Processing extent and click Extent

11. Expand Raster Analysis and click Cell size

12. Click Value

5
13. Expand Processing Extent. Set the Extent by clicking the drop-down arrow and
selecting Same as Layer Hillshade.
14. Expand Raster Analysis. Set the Cell Size by clicking the drop-down arrow and
selecting As specified Below and give the value 10 as cell size in next box The cell size
of your elevation layer will be applied to all subsequent raster outputs.

Click ok
Click save button

6
The model's properties are updated. If at any point you want to close the model and carry on
later, right-click the model in the ArcToolbox window and click Edit to continue.

Building the Model

1. From your table of contents, drag the layers hillshade, recreational sites, and existing
schools onto your model.
2. Click and drag the Slope tool from the Spatial Analyst Surface toolset onto your model
and place it in line with your elevation data. An element that references the Slope tool is
created on the display window.
3. Locate the Euclidean Distance tool in the Spatial Analyst Tools toolbox Distance toolset.
Click and drag the Euclidean Distance tool onto your model and place it in line with
recreational sites.
4. Repeat the previous step, but this time place the Euclidean Distance tool in line with
schools.
Notice that each time the same tool is added to a model, the name of the tool element is
appended with a number. The second time Euclidean Distance was added to your model, the
label consisted of the tool name followed by (2). You can change these labels if you desire, but
this is unnecessary for this example.

5. Click the Add Connection tool .


6. Use the Add Connection tool to connect to the hillshade dataset to the Slope tool. To do this,
click elevation, then click the Slope tool. Then choose input raster from the appearing list.
7. Repeat the previous step, this time connecting recreation sites to the Euclidean Distance tool
and schools to the Euclidean Distance (2) tool. Choose input raster or feature data set from the
appearing list for both cases.

7
8. On the model toolbar, click the Select tool , because you no longer need the Add Connection
tool.
9. Click the Auto Layout button , then click the Full View button to apply the current diagram
properties to the elements and place them within the display window.
10. On the toolbar, click the Save button .

Deriving slope from hillshade data

1. Right-click the Slope tool and click Open, or double-click the Slope tool.
2. Leave the Input raster and the Output measurement as the default values.
3. Accept the default location for the value of the Output raster parameter, but type
slope_out for the name.
4. For the Z factor, type 0.3048 to convert the z-values to the same unit of measure as the
x,y units (from feet to meters).
5. Click OK.

6. Right-click the output variable from the Slope tool and click Rename.
7. Type Slope output and click OK.

Deriving distance from recreation sites

To find locations close to recreation sites, you must first calculate the Euclidean (straight-line)
distance from recreation sites.

1. Hover over the Euclidean Distance tool connected to recreation sites. You can easily see all
the default parameters set for this tool. There is no need to adjust any of these parameters. You
8
accepted the default for the Maximum distance, thus leaving this parameter empty. Therefore,
the edge of the output raster is used as the maximum distance. The Output cell size is taken
from the environment setting previously set to that of your elevation data. In this exercise, the
Output direction raster is not required.
2. Rename the output variable from the Euclidean Distance tool to Distance to recreation sites.

Deriving distance from schools


To find locations away from existing schools, you must first calculate the Euclidean (straight-
line) distance from schools.

1. Hover over the Euclidean Distance (2) tool connected to schools. You can easily see all the
default parameters set for this tool. There is no need to adjust any of these parameters.
2. Rename the output variable from the Euclidean Distance (2) tool to Distance to schools.

Run Model to Derive Datasets

1. Right-click each of the output variables (Slope output, Distance to recreation sites, and
Distance to schools) and click Add To Display.

With the Add To Display property on, the data referenced by the variable will be added to the
display each time the model is run.
2. Click the Run button on the model toolbar to execute the three tools— Slope, Euclidean
Distance, and Euclidean Distance (2) —in your model.

Notice that as the tool runs, its progress is documented on the progress dialog box, and the tool
that references the tool is highlighted in red. When the tools have finished running, the tool and
its output become shaded, indicating that the output has been created on disk.

3. If the progress dialog box is present, check the Close this dialog when completed
successfully check box, then click Close.

Examine the layers added to your ArcMap display.

9
On the Slope Output layer, steep slopes are displayed in red and less steep slopes in green in the
output layer. On the Distance to recreation sites layer, distances increase the farther you are from
a recreation site. On the Distance to schools layer, distances increase the farther you are from a
school.

Reclassifying derived data

Deriving datasets, such as slope, is the first step when building a suitability model. Each cell in
your study area now has a value for each input criteria (slope, land use, distance to recreation
sites, and distance to schools). You need to combine the derived datasets so you can create your
suitability map that will identify the potential locations for the new school. However, it is not
possible to combine them in their present form—for example, combining a cell value in which
slope equals 15 degrees with a cell value for land use that equals 7 (forest)—and get a
meaningful answer that you can compare to other locations. To combine the datasets, they first
need to be set to a common measurement scale, such as 1 to 10. That common measurement
scale is what determines how suitable a particular location—each cell—is for building a new
school. Higher values indicate more suitable locations for the school.

Using the Weighted Overlay tool, you can weight the values of each dataset, then combine them.
However, the inputs for the Weighted Overlay tool must contain discrete, integer values.
Landuse data is already categorized into discrete values; for example, paddy equals a value of 1,
so you can simply add this dataset directly into the Weighted Overlay tool and assign each cell a
new value on the common measurement scale of 1 to 10 (you'll do this later in the tutorial). The
values in the datasets you derived in previous steps are all floating-point, continuous datasets,
categorized into ranges, and they must first be reclassified so that each range of values is
assigned one discrete integer value. Potentially, the value given to each range can be any
number, provided you note the range that the value corresponds to. This is because you can
weight these values within the Weighted Overlay tool—the next step after reclassifying the
derived datasets. However, it is easier to weight the cell values for derived datasets while
reclassifying. In the Weighted Overlay tool, you can accept the default and leave the scale values
the same as the input values. You will reclassify each derived dataset to a common measurement
scale, giving each range a discrete integer value between 1 and 10. Higher values will be given to
attributes within each dataset that are more suitable for locating the school.

1. Locate the Reclassify tool in the Spatial Analyst Tools toolbox Reclass toolset. Click and
drag the Reclassify tool onto ModelBuilder in line with Slope Output. Add another
Reclassify tool in line with Distance to recreation sites and another in line with Distance
to schools.
2. Click the Add Connection tool . Use the connect tool to connect:
a. Slope Output to the Reclassify tool
b. Distance to recreation sites to the Reclassify tool
c. Distance to schools to the Reclassify tool
3. On the model toolbar, click the Select tool .
4. Click the Auto Layout button , then click the Full View button .

10
Reclassifying slope

It is preferable that the new school site be located on relatively flat ground. You'll reclassify the
slope output, slicing the values into equal intervals. You'll assign a value of 10 to the most
suitable range of slopes (those with the lowest angle of slope) and 1 to the least suitable range of
slopes (those with the steepest angle of slope) and rank the values in between linearly.

1. Open the Reclassify tool connected to the Slope Output variable.


2. Accept the default for the Reclass field parameter so the Value field will be used.
3. Click Classify.

4. Click the Method drop-down arrow and click Equal Interval.


5. Click the Classes drop-down arrow and click 10.
6. Click OK.

11
7.Click Reverse New Values.
Reversing the values applies higher new values to the values representing less steep slope, since
these areas are more suitable for building.
8. Accept the default for the Output raster parameter.
9. click ok

12
Rename the output variable from the Reclassify tool to Reclassed slope.

Reclassifying distance to recreation sites

The school should be located as close as possible to a recreational facility. You will reclassify
the distance to recreation sites output, assigning the number 10 to ranges of values that represent
areas closest to recreation sites (the most suitable locations), assigning the number 1 to ranges of
values that represent areas far from recreation sites (the least suitable locations), and ranking the
values linearly in between.

Steps:
1. Open the Reclassify tool connected to the Distance to recreation sites variable.
2. Accept the default for the Reclass field parameter so the Value field will be used.
3. Click Classify.
4. Set the Method to Equal Interval and the number of Classes to 10.
5. Click OK.
6. Click Reverse New Values.
Clicking Reverse New Values makes it so that distances close to recreational facilities receive a
higher new value, since these areas are more desirable.
7. Accept the default path and name for the Output raster parameter.
8. Click OK.

13
Rename the output variable from the Reclassify tool to Reclassed distance to recreation sites.

Reclassifying distance to schools

It is necessary to locate the new school away from existing schools to avoid encroaching on their
catchment areas. You will reclassify the Distance to schools layer, assigning a value of 10 to
areas farthest from existing schools (the most suitable locations), assigning a value of 1 to areas
near existing schools (the least suitable locations), and ranking the values in between linearly. By
doing this, you will determine which areas are near and which areas are far from existing
schools.

1. Open Reclassify (3) tool.


2. Accept the default for the Reclass field parameter so the Value field will be used.
3. Click Classify.
4. Set the Method to Equal Interval and the number of Classes to 10.
5. Click OK.
You want to position the school away from existing schools, so you will assign larger numbers to
ranges of values that represent locations farther away, because these locations are most desirable.
Since the default assigns high New values (more suitable locations) to higher ranges of Old
values (locations farther away from existing schools), you do not need to change any values at
this time.
6. Accept the default for the Output raster parameter.
7. Click OK.

14
Rename the output variable from the Reclassify tool to Reclassed distance to schools.

Executing Reclassify

1. Right-click each of the variable outputs— Reclassed slope, Reclassed distance to recreation
sites and Reclassed distance to schools —and click Add To Display.
2. Click the Run button to execute the three Reclassify tools in your model.
3. On the toolbar, click the Save button .
4. Examine the layers added to your ArcMap display.

Weighting and combining datasets


You are now ready to combine the reclassified datasets and land use to find the most suitable
locations. The values of the reclassified datasets representing slope, distance to recreation sites,
and distance to schools have all been reclassified to a common measurement scale (more suitable
cells have higher values). The landuse dataset is still in its original form because you can weight
the cell values for this dataset as part of the weighted overlay process. Values representing areas
of paddy and roads will be restricted. You'll also mark slope values that are less than 4 (the least
suitable because they are too steep) as restricted so these values can be excluded. If all datasets
were equally important, you could simply combine them, giving each equal influence; however,
15
you have been informed that it is preferable to locate the new school close to recreational
facilities and away from other schools. You will weight all the inputs, assigning each a
percentage of influence. The higher the percentage, the more influence a particular input will
have in the suitability model.

You will assign the inputs the following percentages of influence:


Reclassed distance to rec_sites: 50%
Reclassed distance to schools: 25%
Reclassed slope: 13%
landuse: 12%

Click and drag the Weighted Overlay tool, located in the Spatial Analyst toolbox Overlay toolset,
into ModelBuilder.

Weighted Overlay

1. Open the Weighted Overlay tool.


2. Type 1, 10, and 1 in the From, To, and By text boxes.
The default evaluation scale is from 1 to 9 by 1. A scale of 1 to 10 was used when reclassifying
datasets, so before adding input rasters to the Weighted Overlay tool, you want to set the
evaluation scale from 1 to 10 by 1. This means you will avoid having to update the scale values
after adding your input datasets.
3. Click Apply.
16
Add the Reclassed slope to the Weighted Overlay tool.
a. Click the Add raster row button .
b. For the input raster, select Reclassed slope from the drop-down list and leave the input field as
Value.
c. Click OK.

The raster is added to the Weighted Overlay Table. The Field column displays the values of the
Reclassed slope data. The Scale Value column mimics the Field column because the Evaluation
scale was set to encompass the range of values in each input raster. You could modify the Scale
Values for each class at this point, but for this input, the values were already weighted
appropriately at the time of reclassifying.
5. Repeat the previous step for each of the reclassified datasets including Reclassed distance to
recreation sites and Reclassed distance to schools.
6. For the Reclassed slope input, in the Scale Value column, click the cell with a value of 1.

7. Click the drop-down arrow, scroll, then click Restricted.

17
You know you don't want to build on slopes greater than about 33 percent, even if all other
conditions are ideal. You'll make values from 1 to 3 restricted, since these values represent
slopes from 33.431043 to 47.758633 (the maximum slope).
8. Set Scale Values of 2 and 3 to Restricted.

You'll now weight the scale values of the landuse layer so they are comparable with the other
inputs. A lower value indicates that a particular land-use type is less suitable for building. The
scale values for paddy and roads will be set as Restricted, since they cannot be built on and
should be excluded.

10. Change the default Scale Values for the landuse layer to the following values:
 coconut – 8
 Garden – 10

18
You'll now assign a percentage of influence to each raster, based on how much importance (or
weight) each should have in the final suitability map.

13. In the % Influence column, type the percentages for each of the input rasters:
• Reclassed distance to schools to 25
• Reclassed distance to recreation sites to 50
• Reclassed slope to 13

landuse
to 12

Accept the default for the Output raster parameter.


15. Click OK.

Executing Weighted Overlay

1. Click the Auto Layout button , then click the Full View button .
2. Rename the output variable from the Weighted Overlay tool to Suitable Areas and click OK.
3. Right-click the Suitable Areas variable and click Add To Display.
4. Run the Weighted Overlay tool.
5. On the toolbar, click the Save button .

Examine the layer added to your ArcMap display. Locations with higher values indicate more
suitable sites—areas that are on less steep slopes of suitable land-use types, closer to recreational
facilities, and away from existing schools. Notice that the areas you marked as restricted have a
value of zero.

19
Selecting optimal sites

On your layer, each pixel has a value that indicates how suitable that location is for a new school.
Pixels with the value of 9 are most suitable, and pixels with the value of 0 are not suitable.
Therefore, the optimal site location for a new school has the value of 9. Another criteria for an
optimal location is the size of the suitable area. A suitable location would include several pixels
with value of 9 being connected. This section of your model will look like the following:

Extract optimal sites using the Con tool

You will use a conditional expression in the Con tool to extract only the optimal sites. It has been
decided that those sites that are considered optimal must have a suitability value of 9 (the highest
value in the suit_areas output). In the conditional expression, all areas with a value of 9 will
retain their original value (9). Areas with a value of less than 9 will be changed to NoData.

1. Click and drag the Con tool, located in the Conditional toolset, into ModelBuilder.
2. Open the Con tool.
3. Click the Input Conditional Raster value drop-down arrow and click the Suitable Areas
variable.
4. Type the condition Value = 9 for the value of the Expression parameter.

20
5. Click the Input true raster or constant value drop-down arrow and click the Suitable Areas
variable.
If the condition you enter is true, then the value of the cells of the Input true raster or constant
value will be applied to the cells of the output raster.
6. Leave the value for the Input false raster or constant value parameter blank.
Leaving the Input false raster or constant value parameter blank will apply the default. The
default is that if any value in the Input conditional raster that doesn't meet the condition you
enter will be assigned NoData in the output raster.
7. Accept the default for the Output raster parameter.

Click the Auto Layout button , then click the Full View button .
10. Rename the output variable from the Con tool to Optimal areas and click OK.
11. Right-click Optimal areas and click Add To Display.
12. Run the Con tool.

Examine the layer added to your ArcMap display. These are the optimal site locations for the
new school. There are many single cells representing optimal locations. These 10-meter cells are
too small for the school site. You'll clean up the result, removing these small areas, using the
Majority Filter tool.

Refine the optimal areas using Majority Filter tool

1. Click the Majority Filter tool, located in the Spatial Analyst Tools toolbox Generalization
toolset, and add it to ModelBuilder.
2. Open the Majority Filter tool .
3. Click the Input raster drop-down arrow and click the Optimal areas raster variable.
4. Accept the default Output raster parameter.
21
5. Click the Number of neighbors to use drop-down arrow and click EIGHT. This option
specifies the number of neighboring cells to use in the kernel of the filter. The kernel of the filter
will be the eight nearest neighbors (a 3-by-3 cell window) to the present cell.
6. Accept the default to use the MAJORITY as the Replacement threshold.
Using MAJORITY as the Replacement threshold means five out of eight connected cells must
have the same value for the present cell to retain its value.
7. Click OK.

8. Rename the output variable from the Majority Filter tool to Filtered optimal areas.
9. Right-click the Filtered optimal areas and click Add To Display.
10. Run the Majority Filter tool.

Examine the layer added to your ArcMap display. Compare Filtered optimal areas and Optimal
areas. Many optimal areas that were considered too small in area have been removed.

Now you have to overlay the final output with the main roads and check the suitable sites close
to main roads

Then you should find a larger area for the school. For that you need to convert the final output to
a feature class and then calculate the areas of polygons. Then you can findout a suitable larger
area for the new school.

Raster to Polygon

1. Open the Raster To Polygon tool in the Conversion Tools toolbox, inside the From Raster
toolset.
2. Click the Input raster drop-down arrow and click the Filtered optimal areas raster layer.
3. Leave the default for the Field parameter as VALUE.
4. Accept the default Output polygon features parameter path, but change the name to opt_area.

22
5. Leave the default checked to Simplify polygons. The polygons will be simplified to reduce
the stair-step effect when a raster is converted to a polygon.
6. Click OK.

Now you can calculate the areas of polygons.

23

You might also like