You are on page 1of 21

Prof. Dr. D.

Schrder
Page 1

GIS in Hydrology and Water Management - ENWAT

Tutorial: Introduction to ArcGIS


Training Objectives

Present hydrological relevant data in thematic maps ,prepare data for further hydrological
analysis, perform simple spatial analysis related to hydrology and water resource
management:

To get acquaintance with the user interface of ArcGIS


Understand the philosophy of GIS
Learn how to integrate and manage spatial data
Learn how to design thematic maps
Perform analysis on vector data
Build a topological database and perform simple topological analysis
Interpolate raster
Learn how to design common GIS analysis workflows

Given Datasets:
Different data layers for the Watershed of river Rems, a tributary of the river Neckar, are
given, including
Land cover (Corine Land Cover dataset)
Location (location of places in the state of Baden-Wrttemberg)
Soil (from the Waboa dataset)
Groundwater monitoring stations (from the WaBoa dataset)

River Rems (from the WaBoa dataset)


DEM (DGM50 from BGK)
Watershed boundary and sub catchments (derived from DEM)
Orthophoto
Cadastral data (land parcel boundaries and building outlines from the ALK)
Digital landscape model (ATKIS-DLM25)
Climate data
Some auxiliary data

Remark: All the functionality explained in this tutorial is based on ArcGIS 9.2! If you
are using an older version, may be the workflow will be slightly different.
Task 1: Map of land cover of the Rems watershed

To introduce the basics of ArcGIS we will start in designing a first map. The map should
show in appropriate symbology the land cover, the watershed of river Rems as well as the
river network. According to their importance, the tributaries of river Rems should be mapped
in different width. Finally, we want to add map marginals (meta data of the map) like scale
bar, legend, coordinate system information and so forth.

There are twoArcGIS desktop applications:


ArcCatalog
and

ArcMap

ArcCatalog is the application for managing the spatial data, for managing the database design,
and for recording and viewing metadata. ArcMap is used for all mapping and editing tasks, as
well as for map-based analysis, for data conversion and geoprocessing. Using these two

Prof. Dr. D. Schrder


Page 2

GIS in Hydrology and Water Management - ENWAT

applications together, you can perform any GIS task, simple to advanced, including mapping,
data management, geographic analysis, data editing, and geoprocessing.
The ArcGIS desktop applications can be accessed using three software products, each
providing a higher level of functionality:
ArcView provides comprehensive mapping and analysis tools, along with simple
editing and geoprocessing tools.
ArcEditor includes the full functionality of ArcView, with the addition of advanced
editing capabilities.
ArcInfo extends the functionality of both to include advanced geoprocessing.
Main difference is the functionality of the so called ArcToolbox . The complete ArcToolbox
comes only with ArcInfo, a lighter version comes with ArcView and ArcEditor. ArcToolbox
for ArcInfo comes with a complete, comprehensive set of tools (well over 150) for
geoprocessing, data conversion, map sheet management, overlay analysis, map projection,
and much more. ArcToolbox for ArcView and ArcEditor contains more than 20 commonly
used tools for data conversion and management.
The main task of ArcMap is to visualize spatial related data. The data in ArcMap is organized
as maps. ArcMap stores a map as a map document (a file with the extension *.mxd) so you
can redisplay it, modify it, or share it with other ArcMap users. The map document doesnt
store the actual data, but rather references the data stored on disk along with information
about how it should be displayed. The map document also stores other information about the
map such as its size and the map elements (title, scale bar, and so on).
Geographic information is displayed on a map as layers; each layer represents a particular
type of feature such as streams, lakes, or highways. A layer can only hold one type of
geometry, i.e. points, lines, areas, images, or grids. The geometry type of a layer is shown in
the table of contents. Layers are listed in the ArcMap table of contents and can be further
organized into data frames. A data frame simply groups, in a separate frame, the layers that
you want to display together, i.e. all layers in one data frame can be visualized on one map.
add layers

ArcCatalog

ArcToolbox

MapWindow

Tools icon bar

data frame
point layer
line layer
area layer
table of content

1. Start ArcMap with a new map.


2. Prepare the data frame by setting the output coordinate system and the map units
(right mouse click o the data frame in the TOC -> properties. Use the predefined
projected national grid DHDN 3 Degree Gauss Zone 3). Set the reference scale
(which will be used for annotations) to 1:200 000.
3. Load the shape-file CLC_Rems.shp (Corine land cover), location_BW.shp, river
Rems.shp and Neckar.shp into the map.

Prof. Dr. D. Schrder


Page 3

GIS in Hydrology and Water Management - ENWAT

Hint: if you access several datasets located in the same folder, you should use Connect to
Folder in the Add Data dialog.
The order in which the layers are listed in the TOC is also important. The layers at the top of
the TOC are drawn on top of those below it. You can change the order by drag & drop the
layer's title in the display tab of the TOC.
5. Load the shape file RemsWatershed.shp.
6. Change the display order of the different layers. (Hint: Make always sure that area
layers are at the bottom of the list in the table of content, otherwise they may cover
point and line layers. To see through one area layer, you should set the
symbology and the transparency appropriate; just click on the colored symbol in the
TOC for the specific layer and select one of the predefined fill patterns. For the
transparency use the Display tab of the property dialog of the specific layer)

There are several different buttons and tools in the tools menu for moving around a map (a
button has to be clicked each time you want to repeat the action, a tool stays selected until you
unselect the action):
zoom in/zoom out (either by clicking into the map with a fixed extent or by drawing a box
in the map)
zoom to previous/next extent
pan
zoom to full extent
zoom to layer (select the layer in the TOC and use the right button on the mouse)
zoom to selected feature (to select a feature choose the Select Element-button and click on
the feature or draw a box around it)
7. Test the different tools! (Hint: if the icons are not available, use Tools
->Customize to add them to your user interface or right mouse click in some empty
space of the tool bar area to see the list of all available tool bars)

To get a nicer layout of our map we want to label some rivers and locations, give a title to the
map and change the displaying style of some features.
8. The meaning of the different land cover codes are given in a database table. Load
the data base table clc_code to your view. You can now join your land cover layer
with the codes from the database. (Right mouse click on the layer in the TOC ->
join). To each land cover polygon the description for the specific code of this
polygon will be added in its attribute table temporarily.
9. After joining, you can use the joined attributes to create a thematic map, i.e. to
change the symbology so it is determined by the value of the attribute description.
Use a meaningful symbology for each of the different land cover classes.
10. Save the land cover as a new layer, so we can reuse the defined symbology in
other projects using Save to layer from the context menu of the layer.

Prof. Dr. D. Schrder


Page 4

GIS in Hydrology and Water Management - ENWAT

Another possibility for mapping an


attribute value is to change the size or
width of a symbol or line.
11. The attribute table of the river Rems
contains the attribute GKZ_Stufe,
which is the level of the stream code
(Gewsserkennzeichen). Use the level
to show the river network in different
line width.

Labeling is the process of placing a descriptive text string next to one or more features on
your map. Labels help a map reader to interpret a map. How you label your maps depends on
the type of data youre displaying, what features you want to label, and how youll ultimately
use the map.
In ArcMap you have to distinguish between labels and annotation. Labels are placed
dynamically and the displayed value is derived from an attribute of the features, whereas
annotations are texts which are no longer linked to the original features (except you link it
explicitly to the feature).
To display labels for a layer, you simply specify what attribute of the features you want to
label and then turn labeling on (double click on the layer entry you want to label in the TOC
and select the label tab). ArcMap dynamically places labels on or near the features they
describe. You can also control the font, size, and color of the text to help differentiate labels
for different types of features.
As you pan and zoom around your map, ArcMap dynamically adjusts the labels to fit the
available space. At smaller scales, you see fewer labels because ArcMap has less space to
place them. Because fewer features can be labeled, you might want to prioritize the labeling
of some features. For each layer you want to label, you can set its labeling priority. This

Prof. Dr. D. Schrder


Page 5

GIS in Hydrology and Water Management - ENWAT

means that a feature in a layer with a higher priority will be labeled over a feature in another
layer with a lower priority. Similarly, within a single layer you can set labeling priorities on
specific groups of features.
When you need more precise control over label placement, you can convert the dynamic
labels to annotation. Converting labels to annotation allows you to manually control the
labeling of features. The conversion process creates text graphics from the dynamic labels and
displays them on your map. Then you can work with each label, or text graphic,
independently
12. Double click on the Rems layer in the TOC. Click on the label tab and select the
attribute FL_name as Label Field. Repeat the steps for the location layer. Use different
font, color, and size for the labels of the different layers. Now zoom in and out!
13. To control the priority of the labels use the Placement Properties dialog.

When you convert the labels to annotation, you can store them with the map as an annotation
group, or you can store them separately in a geodatabase as an annotation feature class and
reference it like other data on your map. Storing annotation in a geodatabase is similar to
storing geographic features - line, point, and polygon - in a geodatabase. You can add
annotation stored in a geodatabase to any map. It appears as an annotation layer in the table of
contents. Labels stored as an annotation group in the map document will be deleted as you
delete the map.
Remark: For storing annotation in a database, i.e. an Access mdb-file, the database has to
exist. To create a new one, you have to use ArcCatalog. Some additional settings as the
specification of the coordinate system and the precision of the coordinates are necessary.
Stored annotations in a database are handled as text layers, i.e. can they can only be changed
using the edit tools as for point, line or area layers.
14. Use Convert Labels to Annotation (right mouse click on the layer) to store the labels
shown in your actual extent and store them in the map. You can now move the labels
where you like. To move a label, click the Select Element tool from the Drawing bar
and click on the label you want to move. To change the layout of the selected label,
use the property dialog (right mouse click on the selected label)
15. Add a title to your map using the New text tool from the drawing bar. The text can be
moved and resized in the same way as labels.

Remark: Both the annotations stored in the map as well as the title are graphic elements and
not geographic features. Thus they have to be manipulated differently than features!
If you are satisfied with your map layout, you can start to prepare the map for final printing:
16. From the View menu, choose Layout View. In the Layout View you can arrange the
final layout for your map. Most important of course is the data frame, showing your
geographic information. In addition to a data frame, most maps contain one or more
other map elements. These include titles, North arrows, legends, scale bars, scale
text, graphs, reports, text labels, and graphics. One challenge of cartography is to
arrange the elements of the map on the page to create a useful, visually pleasing
map. You can add these elements manually (use the Insert menu) or you can use
predefined templates (use Change Layout from the Layout tool bar).
17. By clicking on an object in the layout view, you can change some properties of the
layout, e.g. the scale, the properties of the scale bar, the north arrow, etc. The
contents can not be changed here. By default, ArcMap maintains a live link between
the layout view and the data view. This means that changes you make to the data
view are immediately reflected in the layout.

Prof. Dr. D. Schrder


Page 6

GIS in Hydrology and Water Management - ENWAT

Hint: you can add a second map, e.g. an overview map by adding a new data frame to the
TOC and design this map again in the Data View. Remember, only one data frame can be the
active one!
Some properties important for the final layout are only accessible by the property dialog of
the data frame, e.g. grid and graticules.
After you have finished preparing the layout, you can print your map (use the print preview to
check the final layout) as usual.
Before leaving your work, you dont forget to save your work! Make sure that you have
selected the right folder!

Prof. Dr. D. Schrder


Page 7

GIS in Hydrology and Water Management - ENWAT

Task 2: Diagram map of the land cover balance for the Rems catchments

In the following task, a more complex workflow is shown. The aim is to create a diagram
map, i.e. a map showing on a pie chart the share of each land cover in a geographical unit.
Before we start, some hints for improving an interactive map are given.
Usually, to each geographical feature additional attributes are linked. The advantage of a
digital interactive map is, that the information about these attributes can be retrieved. To see
the attributes for an individual feature you have just to point to them. (Click the Identify
button on the Tools bar, than click the mouse pointer over the map feature you want to
identify. The features in all visible layers under the pointer will be identified.)
One of the feature attributes can be used as a map tip. To define a map tip, here are the steps
you have to do: In the table of contents, right-click the layer for which you want to display
map tips and click Properties. Click the Display tab and check Show Map Tips. Click the
Fields tab. Click the Primary Display Field dropdown arrow and click the attribute field you
want to display as the map tip. Click OK. Move the mouse pointer over a feature to see the
map tip.
The attributes belonging to the geometric features of a shape-File are stored in a dBase-file
with the extension dbf. The data to a layer can be shown in a (database) table (context menu
of layer Open Attribute Table). The layer in a map view and the corresponding table are
linked, i.e. if you select a feature in your map the corresponding entry in the table is
highlighted and vice versa. Of course you can select more than one feature or record by using
the ctrl-key.
A theme's attribute table can often contain a lot of fields. By rearranging, hiding, or renaming
the fields, you can control exactly how the table appears on screen. Use the Fields tab of the
layer property dialog to customize the table view.
By sorting an attribute table you can list the currently selected features on your map in order
of importance. Select a column and use the context menu.
To change data in a table (and in a map view) you have first to activate the edit mode (Editor
-> Start Editing). In this mode you can change a single value, add columns, etc. In new
additional columns you can store for instance some calculated data. For simple editing, you
have to use the edit-icon.

Now we are prepared to arrange our data to design the new map, which should visualize the
share of the different land covers of the sub catchments of the Rems watershed as pie
diagrams. The balance should include the three classes settlement, farmland and forest.
1. Load the catchments shape file (remark: the catchments have been created using the
Spatial Analyst and a DEM with resolution 1" x 1" (ca. 30m 20m in GK projection).
2. Select the catchments inside the Rems watershed using Select by location. The
different operators which can be used for this selection will be discussed in the lecture,
here just use the most general one which is intersect (select all the catchments which
interacts with the geometry of the watershed, i.e. which fall inside the watershed).
3. Create a new layer from the selected (right mouse click on the layer in the TOC
->
Selection. Remark: The layer will not contain any data physically! If you need a real
data set of your selected features, use Data -> Data Export).

Prof. Dr. D. Schrder


Page 8

GIS in Hydrology and Water Management - ENWAT

Next we have to intersect the new catchment layer with the land cover layer. An intersection
is a more complicated tool, as it will calculate new geometries, which will take some time
(Hint: For that reason you should restrict the data sets to be intersected as much as possible
e.g. using Selection by Attribute or Selection by Location). The result of the intersection is a
new polygon shape file with a polygon for each land cover in each catchment.
4. Use the Intersection tool from the ArcToolbox.
As Input layers select the two
layers to intersect.
As result, a new Shape-file will be created. (Hint:
be careful about the location where the new file
will be stored. Rename it to give a more
meaningful name to it)

As we want to have our evaluation for each catchment, we will dissolve the new geometries
using the catchment ID and the different land covers. Dissolve will aggregate features based
on specified attributes. So all geometries of a specific catchment with the same land cover
will be combined to one feature.
5. Use the Dissolve tool from the ArcToolbox.
As Input layer select the intersection layer from the
step before. As dissolve fields use the Catch_ID which
identifies the different catchments and the code2000
which identifies the land cover in the year of the evaluation.
As result, a new Shape-file will be created.

In the next step, we will calculate the size of the


areas for the different land covers in each
catchment. To store these values, new fields have to
be added to the attribute table and then they have to
be populated by the respective values. This
manipulation can be done using the Field
calculator. For simple calculations the syntax is
straight forward, for more sophisticated VBA
(Visual Basic for Application), the included macro
programming language, has to be used. Before
performing the calculation, you have to select those
features for which you want to carry out the
calculation. The Selection by Attributes tool from
the user interface can be used, which allows you to
define SQL like queries as working within a data
base.

Prof. Dr. D. Schrder


Page 9

GIS in Hydrology and Water Management - ENWAT

6. Open the attribute table for your dissolved features. Use Options -> Add field to add
the field area_urban. The calculated values will be floating point numbers, thus use
float or double as Type.
7. Repeat this step for the other two fields area_farm and area_forest.
8. Define a Selection by Attributes query to select all settlement features, i.e. all the
features with clc code between 100 and 199. The selected features will be highlighted
on the map and in the attribute table.
9. Check that the correct features are highlighted in the table. Select the column you
want to populate in the table, which is the area_urban. Right mouse click and use
Calculate geometry.
10. Repeat the steps 7 to 8 for the other two columns.

Now we can use the dissolve tool again to get only one feature for each catchment with the
three new columns. To keep the columns, you have to define what should happen to the
values in the aggregation.
11. Use again the Dissolve tool, Use the catch_ID as Dissolve field. Add the three area
columns as Statistic Fields and define as Statistic Type e.g. SUM (remark: here the
type doesnt matter, as we have only one value in each column for each catchment)

12. Now we are ready to create the diagram map. In the symbology dialog for the layer
select Charts to specify the settings for a diagram map.

The whole workflow is an example for a rather complex analysis and managing process. If
you have to repeat it, it would be rather time consuming and boring. Thus it is a good idea to
store the whole workflow as a script using the model builder. The process chain for the whole
workflow is given below.

Prof. Dr. D. Schrder


Page 10

GIS in Hydrology and Water Management - ENWAT

Prof. Dr. D. Schrder


Page 11

GIS in Hydrology and Water Management - ENWAT

Task 3: Create buffers along rivers

Rivers are generally modeled as linear features, but there are issues that may involve
characteristics of the land near the rivers. Simple constant buffer might be needed to
access the river maintenance, but for protecting a river against non-point source pollution the
width of a buffer will be related to the land cover type. In this tutorial we will use as starting
data with the land cover as a polygon feature class and the river network as linear features.
We are supposed to create a buffer along the rivers whose width depends on the current
land cover near the river.

We start with loading our data to a new project.


3. Load the two shape files Rems.shp and CLC_Rems.shp with the clc codes from the
database table to a new project in ArcMap.
4. Join the codes to the land cover layer.
5. Import the symbology for the land cover from the layer file you have saved in the
project before.

The river reaches from the river Rems layer generally pass several different types of land
cover. On the other hand, one land cover polygon may contain several river reaches. Thus we
have a many-to-many relationship between river reaches and land cover polygons. Thus in the
following step, we have to break this n:n relationship into 1:n relationships. The geometry of
our river reaches has to be split, when a new land cover type is reached. This is done by an
intersection of the rivers and the land cover polygons. In addition, in performing the
intersection, the attributes of the corresponding land cover polygon will be added to the
specific new generated river segment.
4. Intersect the Rems layer and the land cover layer. A new shape file will be created.
5. Check geometry type and the attribute table of the new created layer. It should be still
line including as attribute the land cover description as well as the values for your
buffer zones to be created.

In the next step the buffer zones will be created. They will be based on the field buffer , i.e.
each buffer will have a different width depending on the value stored in the field.
7. Use the Buffer tool from ArcToolbox. Use the intersection result as input, as Distance
the buffer field, Side Full which means a buffer on both sides, End Type Round, and
Dissolve Type All which means only one multipart feature will be created.
8. To check visual the result, set the transparency of the layer e.g. to 30%
(Properties-> Display)

Prof. Dr. D. Schrder


Page 12

GIS in Hydrology and Water Management - ENWAT

Task 4: Assign site properties to monitoring points (spatial join)

To manage monitoring points site characteristics like the surrounding land cover, distance to
the nearest river, surrounding land cover and others are important. In this tutorial we will join
this information to the attribute table of the monitoring points.

First, we will assign the land cover layer attributes to our monitoring stations using a spatial
join. Remark: Check carefully the settings for the coordinate systems of your layers. If they
dont fit, the spatial join will be rejected or give wrong results. If there is no information about
the coordinate system specified, use ArcCatalog to set the proper information.
1. Load the groundwater_monitoring shape
file to your project.
2. Join the attributes of the land cover layer
to the points using a spatial join. The

The result can for instance be used to detect all


monitoring points where the surrounding land cover
2000 is different from that of 1990.
3. Use a Selection by Attributes to detect
the monitoring points with different land
cover for 1990 and 2000.

Next we have to assign the distance from the


nearest river to each monitoring point, which is just
another spatial join. The join dialog will look
different depending on the geometry types of the
features which will be involved.
4. Join the Rems layer file to the monitoring

points using a spatial join. Check the


settings in the dialog box carefully. The
results will be written to a new shape file.
5. Check the result by using different sizes
for the symbols depending on the
distance which have been calculated.

Prof. Dr. D. Schrder


Page 13

GIS in Hydrology and Water Management - ENWAT

Task 5: Defining and tracing a topological network


For doing tracing in a network, first a topological correct network has to be build.
Prerequisite of a geometrical network in ArcGIS are geometrically correct river segments, i.e.
a segment runs from a source to the next junction, from junction to junction, or from junction
to the outlet (sink). In the map below each segment is shown by a different color and number.
More sophisticated hydrological tools like ArcHydro are based on geometric networks.

The topological information of a network, i.e. the edges and junctions as feature classes and
their relationships, will be handled in ArcGIS by database tables. Here a Personal
Geodatabase will be used, which is an Access database file. Inside a geo database, the feature
classes are organized as data sets. A data set is a set of feature classes with common
characteristics, like coordinate system, extent, etc.
The data management in the first steps will be done using ArcCatalog.
1. Create a new Personal Geodatabase. Call it Rems.
2. Inside the database create a new data set. Call it Rems. Assign as coordinate system
DHDN_3_Degree_Gauss_Zone_3.
3. Import the Rems shape file to the data set. Call the new feature class Rems.

To create a complex network, which is a net with an outlet and defined flow directions, we
need the junctions as a separate point layer. As it doesnt exist, we have first to create a
simple network, just to extract the junctions.
4. From the context menu of the data set Rems start the Build Geometric Network
wizard by clicking New -> Geometric Network.
5. Follow the wizard using existing features, layer Rems on which you want to base your
network, NO complex edges, YES to snap the edges and junctions, NO weights.
(Hint: if the first run for building the network fails, remove the zombie net, and start a
second time using NO for preserving enable settings). The (simple) net topology as
well as a new layer with the junctions has been created.
6. Export the new junction layer to a shape file.
7. Delete your simple network layer, as we will now create a complex network.

In the next steps, a complex network will be build. A complex network includes at least one
sink, so that the flow direction can be determined.
8. Import the junctions you have created to the data set. Call it Rems_Junction.
9. Use again the Build Geometric Network wizard with the following settings: using
existing features, Rems and Rems_Junction as feature on which you want to build
your network, No enable all network features, YES for building complex edges, No for
snapping, YES for sinks and sources, No for weights.

Prof. Dr. D. Schrder


Page 14

GIS in Hydrology and Water Management - ENWAT

After creating our network, we will analyse it using ArcMap. First we have to set the sink, i.e.
the outlet point, and the flow directions for each segment.
10.
11.

12.

13.

Start ArcMap and add your


data set to the new project.
Use the Editor tool bar to start
the editing process. Make
sure that your target is the
Rems_junction feature class.
From the toolbar use
Attributes and select the most
downstream junction. Set the
AncillaryRole attribute to sink.
Save the edits.

Now we will use the Utility Network Analyst to set the flow direction and to do the tracing.
14. Add the Utility Network Analyst tool bar to your user interface.
15. Use the Set Flow Direction tool to create and Flow -> Display Arrows to check the result.

Settings flags, simple tracing can now be done on the network by using the Solve button..

Prof. Dr. D. Schrder


Page 15

GIS in Hydrology and Water Management - ENWAT

Task 6: Georeferencing an image and digitizing geometry


Up to now we have only used given data sets. If no legacy data is available or no data in the
representation (vector or raster) you need, you have to capture it on your own. In the
following it is assumed that the banklines of the river Rems are needed in vector
representation for further analysis, e.g. as input for a hydrological model. As data only a
clipping of a grey color orthophoto is available. Thus we have first to georeference the image
and then to digitize the river banks as new line features. For georeferencing, cadastral data
(building outlines) are available, which have already coordinates with respect to the DHDN
in the Gauss-Krueger-projection zone 3.
Image pixels are stored in rows and columns, with the image's origin in the upper left-hand
corner. When you add an image to a view, ArcGIS transforms the image coordinates into realworld x and y coordinates. In order to perform this transformation, ArcGIS looks for
georeferencing information stored with the image. Some image files (e.g. BIL, BSQ, BIP,
GeoTIFF) contain information in their header file. This information can also be stored in a
separate ASCII file, a so called world file, because it contains the real-world transformation
information used by the image. The world file has a higher priority than a header file, so you
can override the transformation in an image's header file by creating your own world file. For
other formats, where the header cant contain any georeferencing information, you have
always to store the information in a world file.
Here's the content of a typical world file:
12.01 the x-scale (dimension of a pixel in x direction in map units)
0.0 rotation for row
0.0 rotation for column
-12.01 the y-scale (dimension of a pixel in y direction in map units, attention: the axis is
pointing down!)
128522.92 x coordinate of the center of the upper-left pixel in map units
438509.44 y coordinate of the center of the upper-left pixel in map units
An image's world file uses the same name as the image, the first and third characters of the
image file's extension, plus a final "w" are used for the world file extension (e.g. *.blw for the
BIL format, *.jgw for the JPEG format, *.pgw for PNG format and so on.) The world file has
to be located in the same folder as the image file!
If there is no information available about location of your image, you have to georeference it
manually. Generally, youll align your raster to existing spatial data, such as a shape layer,
that resides in the desired map coordinate system. This assumes that there are features in your
spatial data (target data) that are also visible in the raster - for example, streets, building
footprints, and streams. The basic procedure for georeferencing is to move the raster into the
same space as the target data by identifying a series of ground control points of known x,y
coordinates - that link locations on the raster with locations in the target data in map
coordinates. A combination of one control point on the raster and the corresponding control
point on the target data is called a link.
The number of links you need to create depends on the method you plan to use to transform
the raster to map coordinates. However, adding more links will not necessarily yield a better
registration. If possible, you should spread the links out over the entire raster rather than
concentrating them in one area. Typically, having at least one link near each corner of the
raster and a few throughout the interior produces the best results. In general, the greater the

Prof. Dr. D. Schrder


Page 16

GIS in Hydrology and Water Management - ENWAT

overlap between the raster and target data, the better the alignment results because youll have
more widely spaced points with which to georeference the raster. For example, if your target
data only occupies one quarter of the area of your raster, the points you could use to align the
raster would be confined to that area of overlap. You can only assume that areas outside the
overlap area are properly aligned. To link source and target point, use the georeference tool
bar.
link table

add control points

When youve created enough links, you can transform or warp - the raster to map
coordinates. Warping uses a mathematical transformation to determine the correct map
coordinate location for each cell in the raster. Use a first order - or affine - transformation to
shift, scale, and rotate your raster. Straight lines on the raster are mapped onto straight lines in
the warped raster. Thus squares and rectangles on the raster are commonly changed into
parallelograms of arbitrary scaling and angle orientation. A first-order transformation will
probably handle most of your georeferencing requirements. With the minimum of three links,
the mathematical equation used with a first-order transformation can exactly map each raster
point to the target location. Any more than three links introduces errors, or residuals, that are
distributed throughout all the links. In practice, add more than three links. Given only three, if
one link is positionally wrong, it has a much greater impact on the transformation. Thus, even
though the mathematical transformation error may increase as you create more links; the
overall accuracy of the transformation will increase as well.
The degree to which the
transformation can accurately map
all control points can be measured
mathematically by comparing the
actual location of the map
coordinate to the transformed
position in the raster. The distance
between these two points is known
as the residual error. The total error
is computed by taking the root
mean square (RMS) sum of all the
residuals to compute the RMS
error. This value describes how
consistent the transformation is between the different control points. While the RMS error is a
good assessment of the accuracy of the transformation, dont confuse a low RMS error with
an accurate registration. The transformation may still contain significant errors, for example,
due to a poorly entered control point.
Remark: When you load an image file for the first time, you will be asked if you like to
calculate image pyramids. An image pyramid contains the same image in different level on
details, i.e. in different resolutions. ArcMap will decide depending on the actual scale which
one to load. Thus calculating image pyramids will in general speed up the process of image
loading.

Prof. Dr. D. Schrder


Page 17

GIS in Hydrology and Water Management - ENWAT

1. The shape-file building.shp contains the footprints of buildings near some part of the
river Rems. The tif-file cut7120_78s.tif contains a clip of an orthophoto. The building
data is with respect to the datum of the DHDN in Gauss-Krger projection zone 3. Use
ArcCatalog to define the appropriate coordinate system for the shape file.
2. Load both layer to your project in ArcMap.
3. Use the georeferencing tool bar to georeference the orthophoto. Zoom to your vector
data such that it fills your map window, than use Fit to Display to shift the orthophoto
roughly. Use a symbology for your buildings with helps to identify their outline, e.g. use
no fill color and yellow for the outline.
4. Now you have to identify link points, i.e. first click on the photo, second click on the
corresponding corner point of the building outline of the vector data. Your RMS should
be ca. 1 m for 8 points at least covering the whole photo. Use the link table to check
the residuals for the individual points. Points with a very large value are outliers and
should be deleted.
5. Use an affine (first order) transformation to warp the photo. Dont forget to update your
georeferencing: two files (*.aux and *.tfw will be written with the georeferencing
information).

ArcCatalog lets you create new shapefiles and dBASE tables and modify them by adding,
deleting, and indexing attributes. You can also define a shapefiles coordinate system and
update its spatial index. While you can change the structure and properties of a shapefile in
ArcCatalog, you must use ArcMap to modify its features and attributes - for example, to add
values into a new column by performing a calculation on values in another column. So we
will use ArcCatalog to create a new empty shapefile to store our river bank lines.
1. Start ArcCatalog and browse to the folder where your project shapefiles are located.
Right click the folder name and select New -> Shapefile from the menu.
2. In the dialog, enter a name for your new shapefile layer and make sure that the
feature type Polyline is selected. Change the setting for the coordinate system to
DHDN zone 3.
3. Change to the table view in ArcCatalog and add the fields to your shapefile you need
to store the attributive data. Make sure to use the appropriate data types. Here we
want to store the river name and the location of the bank line with respect to the river,
i.e. left or right.
4. Add your new created shapefile as a new layer to your map in ArcMap.
5. Start your editing session from the Edit toolbar. Select the task (Create New Feature)
for your target (i.e. the layer, you have just created).
6. Add the vertexes to the layer by clicking the left mouse button in the map. Make sure
that every start point of a new line exactly snaps on the end point of the previous line
(use the snapping settings you find in the Options of the Editor tool bar)
7. Open the attribute table and enter values into the fields for each line by using the Edit
tool.
8. Dont forget to stop the edit session to save your changes.

Prof. Dr. D. Schrder


Page 18

GIS in Hydrology and Water Management - ENWAT

Task 7: Determine areal precipitation by the Thiessen method


Areal precipitation is frequently estimated by a weighted mean of measured precipitation at
rain gauges in and near the watershed. As input for hydrological models, often Thiessen
polygons are needed, which assigns the value of the closest observation point to each point in
the domain. In this tutorial Thiessen polygons will be created for calculating the average
annual rainfall for the whole Rems watershed.
As input data, the locations shape file (cities and other settlement locations) and a text file
with rainfall data will be used (precipitation.tab). The text file contains the name of the
station, the precipitation for each month, and the summed up yearly precipitation. The
columns are separated by a tab.
1. Load the two files and join them using the common
field, i.e. the names of the locations. Use the
Advanced button to keep only those rows which
have a match in the other table (28 locations)
2. Export the joined result to a new shape file and add
it to your project.
3. Create the Thiessen polygons based on the file
from step 2. Use the option Output Field ALL to get
the point attributes to the polygons. (Remark: this
only will work on real attributes, not on joined
ones. For that step 2 was necessary.)

Prof. Dr. D. Schrder


Page 19

GIS in Hydrology and Water Management - ENWAT

Now we want to assign weights to the Thiessen polygons


according to their share in the Rems watershed. First we have
to restrict the polygons area to that of the watershed.
4. Use Clip to restrict the polygons to the watershed
area. Use the Rems watershed shapefile as clipping
layer.

Next we have to do some calculations on the attributes. We need the share of each Thiessen
polygon on the whole watershed. We will use VBA for defining the complex calculation.
5. Determine the size of the watershed using the Measurement
tool (hint: to be sure to select the correct feature, turn off all
the other layers.)
6. Add a new field to the attribute table of your Thiessen
polygons called share with data type double.
7. Populate the field using the Field calculator using the formula
Dim Output as double
Dim pArea as Iarea
Set pArea = [shape]
Output = [sum] * pArea.area/583117904

For calculating the average annual rainfall for the whole watershed, we can use the statistics
for our new column.

Prof. Dr. D. Schrder


Page 20

GIS in Hydrology and Water Management - ENWAT

Task 8: Determine areal precipitation by Grid interpolation

Another possibility to the calculation of the average annual rainfall is to uses raster tools.
Here we have first to interpolate the sparse data from the climate stations to a dense raster.
Than the raster values can be summed up considering the size of each pixel.
1. Load the shape file with the location and their precipitation data you have created in
the preceding tutorial.
2. Activate the Spatial Analyst Extension and add its toolbar to your GUI.
3. Interpolate the location to a raster. Make sure to use the sum of precipitation as Z
value field. Try the IDW and the Spline interpolation with different settings for the
parameters. Use a reasonable cell size for your raster. (Remark: a temporarily created
raster will be stored when you exit ArcMap (but in the default folder!), you can make it
permanently by exporting it to a grid.

As we are only interested in the cells inside the watershed, we have to clip the result again.
Clipping of a raster, i.e. extracting the raster cells covered by another layer is called masking.
4. Use the Mask tool from the Spatial Analyst Tools of the ArcToolbox. As input raster,
use your final interpolation, as feature mask data the Rems watershed layer. Check the
folder for saving the result raster.
5. As the result of the interpolation was a floating point layer, we have no VAT associated
with the raster that means we can not perform any calculations based on attributes. So
we have to convert it to an integer layer using the raster calculator
6. In the VAT we have one row entry for each class, i.e. cells with the same value. Each
row includes the value and the number of pixels with this value. To calculate the average
annual rainfall, we have just to multiply the values with their number of occurrence, some
them up and divide the result by the total number of cells. Use the Zonal statistic tool to
get the sum, i.e. the number of cells times their values.
7. With the statistics of the column sum you get the summed up cell values, use a
calculator to divide it by the total number of cells (i.e. the sum of the column count)
8. Compare the result with the result you got from the Thiessen polygon method.

Prof. Dr. D. Schrder


Page 21

GIS in Hydrology and Water Management - ENWAT