GRID Training Course

Environmental Protection Agency
Region IV
September 18 - 22,1995

Instructor:

Dave Riddle, Vice-President Technical Services

A.C.T. GIS, Inc.

108 Canvasback Court
Frankfort, Kentucky 40601
Phone: (502) 695-9314

-------
GRID Training Course

September 16. 1995

Table of Contents

Course Objectives	 1

Grid-Cell Concepts	 4

What is a grid?		 5

Cell Resolution	 5

Cell Values			 5

Registration of Grids	 6

Raster Encoding	 6

GRID Basics	 7

GRID Overview			 7

Types of Grids	 7

Grid Attributes			 7

GRID Display	 9

GRID and AML	9

GRID Analysis	 9

Grid Data Input	 10

Map Algebra	 10

Why Use GRID?	 11

GRID Commands	 13

Invoking GRID	 13

GRID Commands	 13

The ABBREVIATIONS Command	 13

The AP Command	 14

The ARCTOOLS Command	 14

The ATUSAGE Command	 14

The BUELDSTA Command	 14

The BUILDVAT Command	 15

The COMMANDS Command	 15

The COPY Command	 15

The DESCRIBE Command	 16

The HELP Command	 16

The INFO Command	 17

The KILL Command	 17

The LISTCOVERAGES Command	 17

The LlSTGRIDS Command	 17

The LISTIMAGES Command;...:	 17

The LISTSTACKS Command	 18

The LOG Command.....	 18

The PRINTDOC Command	 18

The PROJECTCOMPARE Command..:	 18

The QUIT Command	 19

The RENAME Command	 19

The USAGE Command	 19

The VERIFY Command	 19

ฉ 1995 A.C.T. GIS, Inc.	Page i

-------
GRID Training Course

Saptember 16.1995

Table of Contents (Continued)

The GRID Analysis Environment	 20

The SETCELL Command	 20

The SETWINDOW Command	 20

The SETMASK Command	 21

The RESTORE Command	 22

The SAVE Command	 22

The RESET Command	 22

The SHOW Command	 22

The STATUS Command	 22

Creating GRID Data	 23

Grid Conversion Basics	 23

ARC GRID Conversion Commands	 23

The ARC ASCDGRID Command	 24

The ARCADRGGRID Command	 25

The ARC DEMLATTICE Command	 25

The ARC DTEDGRID Command	 26

The ARC FLOATGRID Command	 26

The ARC IMAGEGRID Command	 27

The ARC LINEGRID Command	 28

The ARC MOSSGRID Command	 29

The ARC POENTGRID Command	 30

The ARC POLYGRID Command	 31

The ARC SVFGRID Command	 32

The ARC TOPOGRID Command	 32

The ARC TOPOGRIDTOOL Command	 34

The = Operator	 35

GRID Data Conversion Functions	 35

The LINEGRID() Function	 36

The POINTGRID() Function	 37

The POLYGRID() Function	 38

GRID Display	 39

GRID Display Overview	 39

GRID Cell Value Transformation	 39

The HISTOGRAM Command	 41

Remap Tables	 42

Colormap Files	 46

The GRID Display Commands	 48

The GRIDNODATASYMBOL Command	 48

The GRIDPAINT Command	 49

The GRIDSHADES Command	 50

The GRIDCOMPOSITE Command	 51

The GRIDDIRECTION Command	52

The GRIDNET Command	 53

ฉ 1995 A.C.T. GIS, Inc.	Page ii

-------
GRID Training Course

September 16. 1995

Table of Contents (Continued)

The IMAGE Command	53

The ARCPLOT SHADECOLORRAMP Command	 54

The LOADCOLORMAP Command	 55

The SAVECOLORMAP Command	 55

The CONVERTREMAP Command	 56

The CREATEREMAP Command	 56

The REMAPGRID Command	 57

The SHADEGRID Command	 58

Querying Grids	 	 59

The CELLVALUE Command	 59

The GREDQUERY Command	 60

GRID Terminology	 61

GRID Spatial Processing Concepts	 62

Location Determination	 62

Cell-byCell Processing	 62

Multi-grid Calculations	 62

Operator and Local Function Processing	 62

Neighborhood Processing	 62

Neighborhood-notation Processing	 62

Zonal Calculations	 63

Calculating Distance and Direction	 63

Weight-distance Calculations	 63

Calculating Area	 63

Surface Calculations	 64

Map Algebra	 65

Map Algebra	 65

Map Algebra Expressions	 66

GRID Commands	 68

Map-algebra Input Types	 68

Map-algebra Results	 68

Multiple Outputs	 69

NOD AT A in GRID	 69

Direct Display of Analysis Results	 70

GRID Functions	 71

Miscellaneous Functions	 71

The ABS Function	 71

The CEIL Function	 72

The CON Function	 73

The FLOAT Function	 75

The FLOOR Function	 76

The FMOD Function	 77

The INT Function	 78

The ISNULL Function	 79

ฉ 1995 A.C.T. GIS, Inc.	Page iii

-------
GRID Training Course

September 16.1995

Table of Contents (Continued)

The MERGE Function	 80

The MOSAIC Function	 81

The NORMAL Function	 82

The PICK Function	 83

The RAND Function	 84

The SAMPLE Function	 85

The SETNULL Function	 87

Individual Cell Processing	 88

The DOCELL Block	 88

The IF Statement	 89

The WHILE Statement	 91

The SCALAR Function	 92

The := Operator	 93

Trigonometric Functions	 94

Logarithmic and Exponential Functions	 95

Statistical Functions	 96

Selection Functions	 98

The SELECT Function	 98

The SELECTBOX Function	100

The SELECTCIRCLE Function	 101

The SELECTMASK Function	 102

The SELECTPOINT Function	 103

The SELECTPOLYGON Function	 104

The TEST Function	 105

Reclassification Functions	 106

The RECLASS Function			 106

The SLICE Function	!	 108

Shape Analysis Functions	 110

The EXPAND Function	 110

The REGIONGROUP Function	 112

The SHRINK Function	 114

The BOUNDARYCLEAN Function	 116

The MAJORITYFILTER Function	 118

The NIBBLE Function	 119

The THIN Function	 120

Projecting Grids	 121

The PROJECT Function	 121

Raster to Vector Conversion	 122

The GRIDLENE Function	 122

The GREDPOENT Function	 123

The GRIDPOLY Function	 123

The ARC GRIDASCH Command	 124

The ARC GRIDLINE Command	 124

ฉ 1995 A.C.T. GIS, Inc.	Page iv

-------
GRID Training Course

September 16.1995

Table of Contents (Continued)

The ARC GRIDPOINT Command	 126

The ARC GRIDPOLY Command	 126

Focal Functions	 127

The FOCALFLOW Function	 127

The FOCALMAJORITY Function		 128

The FOCALMAX Function	 130

The FOCALMEAN Function	 132

The FOCALMEDIAN Function	 134

The FOCALMIN Function	 136

The FOCALRANGE Function	 138

The FOCALSTD Function	 140

The FOCALSUM Function	 142

The FOCALVARIETY Function	144

Zonal Functions	 146

The ZONAL ARE A Function	146

The ZONALFTLL Function	;	147

The ZONALGEOMETRY Function	147

The ZONALMAJORTTY Function	147

The ZONALMAX Function	147

The ZONALMEAN Function	148

The ZONALMEDIAN Function	148

The ZONALMIN Function	148

The ZON ALPERIMETER Function	148

The ZONALRANGE Function	149

The ZONALSTATS Function	149

The ZONALSTD Function	149

The ZONALSUM Function	150

The ZONALTHICKNESS Function	150

The ZONALVARIETY Function	150

Surface Analysis	 151

Surface Analysis	 151

The IDW Function	152

The KRIGING Function	153

The TREND Function	154

The SPLINE Function	154

Surface Defined Grids	 155

The SLOPE Function	155

The ASPECT Function	156

The HILLSHADE Function	157

The SAI Command	158

Distance Functions	 159

ฉ 1995 A.C.T. GIS, Inc.	Page v

-------
GRID Training Course

September 16.1995

Table of Contents (Continued)

Surface Hydrologic Analysis	 160

Surface Hydrologic Analysis	 160

DEMs	 160

Creating a Depressionless DEM	 161

The SINK Function	161

The FILL Command	163

The FLOWDIRECTION Function	164

The FLOW ACCUMULATION Function	165

The FLOWLENGTH Function	166

The BASIN Function	167

The WATERSHED Function	168

The STREAMLINK Function	169

The STREAMLINE Function	169

The STREAMORDER Function	170

The SNAPPOUR Function	170

Groundwater Advection and Dispersion Modeling	 171

The DARC YFLOW Function	 171

The PARTICLETRACK Function	 171

The POROUSPUFF Function	 171

Visibility Functions	 172

The VISDECODE Command	 172

The VISENCODE Command	 172

The VISIBILITY Function	 172

Grid Stacks	 173

The MAKESTACK Command	 174

The STACKSHADE Command	 174

The COPYSTACK Command	 175

The DROPFROMSTACK Command	 176

The STACKSTATS Command.	 176

AML Directives	 177

The &DESCRIBE Directive	 177

AML Functions	 177

The GETGRID Function	 178

The GETIMAGE Function	 180

The GETSTACK Function	 182

ฉ 1995 A.C.T. GIS, Inc.	Page vi

-------
GRID Training Course			September 16, 1995

GRID Training Course Outline

Monday Morning

Introductions

Course Objectives

Grid-Cell Concepts

GRID Basics

GRID Commands

Invoking GRID
GRID Commands

Monday Afternoon

The GRID Analysis Environment

Creating GRID Data

Grid Conversion Basics

ARC GRID Conversion Commands

The = Operator

GRID Data Conversion Functions

Tuesday Morning

GRID Display

GRID Display Overview

GRID Cell Value Transformation

The HISTOGRAM Command

Remap Tables

Colormap Files

GRID Display Commands

Querying Grids

ฉ 1995 A.C.T. GIS, Inc.

Page 1

-------
GRID Training Course

September 16. 1995

GRID Training Course Outline (Continued)

Tuesday Afternoon
GRID Terminology
GRID Spatial Processing Concepts
Map Algebra

Wednesday Morning

GRID Functions

Miscellaneous Functions
Individual Cell Processing
Trigonometric Functions
Logarithmic Functions
Statistical Functions

Wednesday Afternoon

GRID Functions

Selection Functions

Reclassification Functions

Shade Analysis Functions

Projecting Grids

Raster to Vector Conversion

Focal Functions

Zonal Functions

Thursday Morning

Surface Analysis

Surface Analysis Functions

Distance Functions

ฉ1995 A.C.T. GIS, Inc.

Page 2

-------
GRID Training Course			September 16. 1995

GRID Training Course Outline (Continued)

Thursday Afternoon
Surface Hydrologic Analysis
Groundwater Advection and Dispersion

Friday Morning
Visibility Functions
Grid Stacks

AML Directives and Functions

Friday Afternoon
GRID Workshop

ฉ 1995 A.C.T. GIS, Inc.

Page 3

-------
GRID Training Course	September 16.1995

Course Objectives

1.	Address GRID-Cell Concepts

2.	Address GRID Basics

3.	Address Creating GRID Data

4.	Address GRID Commands

5.	Address the GRID Analysis Environment

6.	Address GRID Display and Query

7.	Address GRID Terminology

8.	Address GRID Spatial Processing Concepts

9.	Address Map Algebra

10.	Address GRID Functions

11.	Address Surface Analysis

12.	Address Distance Functions

13.	Address Surface Hydrologic Analysis

14.	Address Groundwater Advection and Dispersion

15.	Address Visibility Functions

16.	Address Grid Stacks

17.	Address AML Directives and Functions

ฉ 1995 A.C.T. GIS, Inc.

Page 4

-------
GRID Training Course

September 16. 1995

Grid-Cell Concepts

What is a grid?

•	Grid-based systems divide the world into discrete uniform units
called cells. Every cell represents a specified portion of the
Earth, such as a square mile or a square meter. Each cell is
assigned a value to correspond to the feature or characteristic
that is located at or describes a site, such as elevation, vegetation
cover, or soil type.

Cell Resolution

•	The cell size chosen for a grid depends on the data resolution
required for the most detailed analysis to be performed.

•	Data loss occurs when detailed vector boundaries are gridded,
with the amount of loss directly dependent upon the cell size
chosen. Homogeneous areas may be gridded with a larger cell
size.

Cell Values

•	Cell values categorize a cell. Values may be integer or floating
point.

•	Four types of cell value measurements are:

1.	Ratio - values are derived relative to a fixed zero point on a
linear scale (i.e. age, distance, weight, and volume)

2.	Interval - values on a linear scale not relative to a true zero
point (i.e. time of day, years, or temperature).

3.	Ordinal - values that determine position (first, second,
third and good, better, best)

4.	Nominal - Values used to identify one instance from
another, or to establish a class, group, or category (landuse
code, soil type, and zip codes)

ฉ 1995 A.C.T. GIS, Inc.

Page 5

-------
GRID Training Course

September 16. 1995

Grid-Cell Concepts (Continued)

Registration of Grids

•	Grids must be registered to a common coordinate system before
performing analysis on multiple grids. Each location on the
ground must be represented by the same x,y coordinate on every
grid.

Raster Encoding

•	The value assigned to a cell depends on the gridding method
used. The four methods for determining cell values are:

1. Centroid - the cell is assigned the value of the feature at
the center of the cell.

Predominant Type (Majority Weighting) - The value of the
feature that fills the majority of the cell is assigned to the
cell.

/ 3.) Most Important - Each cell is assigned the value associated
with the feature that have been specified as most
important to the study.

4. Percentage Breakdown - A cell is assigned several values,
one per feature, according to the percent each feature
occupies within the cell.

• ARC/INFO GRID currently supports the predominant type and
most important type methods.

ฉ 1995 A.C.T. GIS, Inc.

Page 6

-------
GRID Training Course

GRID Basics

September 16.1995

GRID Overview

•	GRID is the ARC/INFO subsystem for creating, analyzing, and
displaying ratser- or cell-based data.

•	Data in GRID is represented as a series of cells. GRID divides
the data in a particular area into a series of consistent sized rows
and columns, with a value assigned to each cell.

Types of Grids

•	There are two types of grids, integer and floating point. Integer
grids represent categorical or discrete data such as soil types or
landuse polygons. Floating point grids represent continuous
data such as elevations, noise contours, or radiation levels
relative to a fixed location or emanating point (such as sea level
or a nuclear accident site).

Grid Attributes

•	In ARC/INFO a grid is similar to a coverage. Each unique grid
cell value has a record in a corresponding value attribute table,
or VAT. A VAT is comparable to a coverage's A AT, PAT, or
NAT.

•	Only integer grids have a VAT.

•	When comparing a grid to a polygon coverage, the primary
difference in the attributes is that in a polygon coverage, the
PAT contains one record for each polygon. In a grid, the VAT
contains one record for each unique grid cell value, thus
reducing storage space.

•	VATs are accessed using INFO just like coverage feature
attribute tables.

ฉ 1995 A.C.T. GIS, Inc.

Page 7

-------
GRID Training Course

September 16. 1995

GRID Basics (Continued)

• A sample VAT appears below:

Grid: list

Usage: LIST  {from} {to} {item...item)

Grid: list mapll.vat

NTT



Record

VALUE

COUNT

1

1

5647

2

2

9940

3

3

828

4

4

116

5

5

1893

6

6

786

7

7

44

8

8

55

9

9

52

10

11

1975

11

12

1372

12

13

7

13

14

1781

14

15

164

15

16

210

16

17

70

17

18

-864

18

19

1034

19

20

145

20

29

1808

21

98

4151

22

99

32794

• A VAT contains two attributes by default. These are VALUE
and COUNT. Value is each unique cell value, and COUNT is
the number of cells in the grid having the corresponding cell
value. An example of a VAT follows:

Grid: items

Usage: ITEMS  
Usage: ITEMS  INFO

Grid: items mapll.vat info

COLUMN ITEM NAME WIDTH OUTPUT

1	VALUE	4	10

2	COUNT	4	10

TYPE N.DEC ALTERNATE NAME INDEXED?
B -	Indexed

B

• VATs can be modified using such ARC commands as
ADDITEM, DROPITEM, and PULLITEMS.

ฉ 1995 A.C.T. GIS, Inc.

Page 8

-------
GRID Training Course	September 16. 1995

GRID Basics (Continued)

•	GRID allows the storage of a single grid with multiple
attributes to describe the cells. New grids can be derived from
one or more attributes.

GRID Display

•	Grids can be displayed in Arcplot, and Arcplot commands are
directly accessible from the Grid: prompt or are accessible by
prefixing the Arcplot command with AP (when command names
are the same between Arcplot and GRID but have different
functions). Various Arcplot commands specifically display
grids.

GRID and AML

•	AMLs can be created to operate within GRID, just like any other
ARC/INFO module. All AML functions, directives, and menus
are available within GRID.

GRID Analysis

•	Functions are grouped into four categories:

1.	Local - per-cell computation of an output grid based on
input cell value at each location. Examples include adding
two grids together to create a new output grid, selecting all
cell values equal to a value and writing them to an output
grid, or changing all unique grid cell values to new unique
output cell values.

2.	Focal - per-neighborhood computation of an output grid
based on the values of cells in a neighborhood (the input
cell and its surrounding cells). Neighborhoods can be the
3x3 cell neighborhood, an extended neighborhood (i.e.
10x10 cells, etc.), or a circular, wedge, or donut shaped
neighborhood. Examples include sum, mean, and
standard deviation of cells in a neighborhood.

ฉ 1995 A.C.T. GIS, Inc.

Page 9

-------
GRID Training Course

	September 16. 1995

GRID Basics (Continued)

3.	Zonal - per-zone computation of output cell values based
on values of cells in a zone (all cells with the same value in
a grid). Examples include mean, sum, min, max, or range
computations.

4.	Global - per-grid computation of output cell values based
on all cell values in a grid. Examples include surface
modeling, Euclidean distance, groundwater, weighted
distance, hydrologic, and multivariate functions.

•	GRID analysis can be performed on grids with different
resolutions (cell sizes). GRID^automatically resamples^the grids
to the coarsest cell size before processing.

•	When insufficient information is available to assign a value to a
cell, the cell can be assigned a NOD ATA value. All GRID
analyses are desired to handle NOD ATA cells.

iV

GRID Data Input

• Data can be input into GRID in one of the following ways:

1.	Coverage to grid conversion (points, lines, or polygons)

2.	Lattice to grid conversion

3.	Image to grid conversion

4.	ASCII file to grid conversion

5.	Floating point binary file to grid conversion

6.	ADRG, DTED, or SVF data to grid conversion

7.	DEM to lattice conversion

Map Algebra

•	Map algebra is a data manipulation language using by GRID to
perform spatial analysis using grid data.

•	GRID provides a wide number of functions used to process grid
data.

1995 A.C.T. GIS, Inc.

Page 10

-------
GRID Training Course

September 16. 1995

GRID Basics (Continued)

•	GRID supports various operators which compute on one or
more input grids. Operators include:

1.	Arithmetic

2.	Boolean

3.	Relational

4.	Bitwise

5.	Combinatorial

6.	Logical

7.	Accumulative

8.	Assignment

•	DOCELL loops allow for conditional and interactive control of
grid cell values on a cell by cell basis.

Why Use GRID?

•	GRID has the ability to represent continuos data such as
surfaces that cannot be represented with a vector data structure.

•	GRID can store point, line, polygon, and surface data in a
common format, allow analysis of all data types simultaneously.

•	Some accuracy might be lost when representing data in a grid
format. Polygons, for example, might become generalized when
converted to grid. The cell resolution determines how
accurately a feature will be represented as a grid.

•	Some application well suited for GRID include:

1.	Hydrologic Analysis

2.	Determination of Subbasin Area Statistics

3.	Determination of Runoff Coefficients

4.	Computation of Subbasin Precipitation

5.	Spatial Display of Erosion and Sediment Disposition

6.	Tracking Pollution Dispersion

7.	Environmental Analysis

8.	Habitat Suitability

ฉ 1995 A.C.T. GIS, Inc.

Page 11

-------
GRID Training Course

September 16. 1995

GRID Basics (Continued)

•	GRID should be used when:

1.	Representing the locational view of geographic data of
both continuous surfaces as well as categorical data.

2.	Modeling of attributes of locations on the Earth's surface

3.	Working with multiple data types in the same
environment

•	GRID is best when:

1.	The attributes of a location are influenced by the attributes
of the locations that surround it (i.e. pH varies depending
of the pH of surrounding areas; visual preference depends
on positive and negative visual effects in an area;
population changes over time due to the composition of
the surrounding population)

2.	The attributes of a location are influenced by where its
position falls within another feature (i.e. locating optimal
habitat; preventing a disease outbreak; or examining
roughness of terrain for determining a building site.

3.	Cell-based systems can be used for continuous surface-
data modeling (i.e. modeling noise in decibels at different
locations from a proposed airport; determining areas
affected by a solid waste dump)

4.	Optimal allocation and surface determinations that can
only be calculated when a surface is divided into discrete
units (i.e. determining the optimal course for a new road
based on soil types; creating a drainage map from a
elevation surface; or identifying locations along a road that
should be preserved for a visual quality assessment study)

•	Vector data is better suited when objects are more important
than location.

ฉ 1995 A.C.T. GIS, Inc.

Page 12

-------
GRID Training Course	September 16. 1995

GRID Commands

Invoking GRID

• GRID is invoked from the Arc: prompt by typing grid. For
example:

Arc: grid

GRID Commands

• The following commands are available from the Grid: prompt:

M <• A Co

ฃ







ABBREVIATIONS

ADDTOSTACK

AP

ARCTOOLS

ATUSAGE

BUILDSTA

BUILDVAT

CELLVALUE

CLASSSAMPLE

COMMANDS

CONVERTREMAP

COPY

COPYSTACK

CORRELATION

CREATEREMAP

DENDROGRAM

DESCRIBE

DRAWSIG

DRAWZONESHAPE

DROPFROMSTACK

EXTERNAL

EXTERNALALL

FILL

FORMEDIT

GEARY

GRIDCOMPOSITE

GRIDEDIT

GRIDNODATASYMBOL

GRIDPAINT

GRIDQUERY

GRIDSHADES

HELP

HISTOGRAM

IMAGE

INDEX ITEM

INFO

KILL

LIST

LISTCOVERAGES

LISTGRIDS

LISTIMAGES

LISTSTACKS

LLSFIT

LOADCOLORMAP

LOG

MAKESTACK

MERGEVAT

MORAN

PRINT

PRINTDOC

PROJECTCOMPARE

QUIT

REGRESSION

REMAPGRID

REMOVESCALAR

RENAME

RESET

RESTORE

SAI

SAVE

SAVECOLORMAP

SCATTERGRAM

SETCELL

SETMASK

SETWINDOW

SHADEGRID

SHOW

STACKHISTOGRAM

STACKSCATTERGRAM

STACKSHADE

STACKSTATUS

STATUS

USAGE

VERIFY

VISDECODE

VISENCODE









•	The following section describes some of the more commonly
used GRID commands.

The ABBREVIATIONS Command

•	Turns command abbreviations on or off.

•	Usage: ABBREVIATIONS 

•	 means all the characters in a GRID function or command
name must be entered.

•	 means function and command names may be
abbreviated.

•	Abbreviations are OFF when GRID is invoked.

ฉ 1995 A.C.T. GIS, Inc.

Page 13

-------
GRID Training Course					September 16.1995

GRID Commands (Continued)

The AF Command

•	Allows entry of Arcplot commands directly from the Grid:
prompt.

•	Usage: AP 

•	AP is only needed for those commands that share the same
name in Arcplot and GRID but behave differently (i.e. RESET,
LIST, and USAGE). All other Arcplot commands are accessible
from the Grid: prompt.

The ARCTOOLS Command

•	Invokes the ArcTools menu interface.

•	Usage: ARCTOOLS {MAP I EDIT I GRID I COMMAND}

The ATUSAGE Command

•	Displays the usage of an ATOOL command

•	Usage: ATUSAGE 

The BUILDSTA Command

•	Builds a statistics file (STA) for a grid based upon the VALUE
item.

•	Usage: BUILDSTA 

•	A statistics file is useful for some GRID commands which need
information about distribution of data such as GRIDSHADES
and GRIDPAINT.

ฉ 1995 A.C.T. GIS, Inc.

Page 14

-------
GRID Training Course					September 16. 1995

GRID Commands (Continued)

The BUILD VAT Command

•	Build a value attribute table (VAT) for a grid.

•	Usage: BUILDVAT 

•	If a VAT does not exist, BUILDVAT creates a VAT with the
items VALUE and COUNT. Otherwise, all items in the VAT are
retained.

The COMMANDS Command

•	Displays GRID functions, commands, and ATOOL commands

•	Usage: COMMANDS {prefix I wildcard}

•	When the COMMANDS command is executed, GRID command
names are followed by "**" and function names are followed by
(). Operators are listed at the end just before GRID ATOOL
commands.

The COPY Command

•	Duplicates a grid or other ARC/INFO geo_dataset.

•	Usage: COPY  {to_geo_dataset}

•	COPY may be executed from both the Arc: and Grid: prompts.

•	The {to_geo_dataset} is optional and if  is in
another workspace, the geo_dataset is copied to the current
workspace with the same geo_dataset name.

•	The {to_geo_dataset} cannot exist in the current workspace.

•	All INFO files with . are copied as
well.

ฉ 1995 A.C.T. GIS, Inc.

Page 15

-------
GRID Training Course

September 16. 1995

GRID Commands (Continued)

The DESCRIBE Commands

•	Provides a description of a grid or other ARC/INFO geo_dataset.

•	Usage: DESCRIBE 

•	DESCRIBE may be executed from both the Arc: and Grid:
prompts.

•	The following example illustrates the DESCRIBE command:

Grid: describe railgrid

Description of Grid /ACT/RIDDLE/FORESITE/WORK1/RAILGRID

Cell Size	= 208.710

Number of Rows = 577
Number of Columns = 359

Data Type:	Integer

Number of Values = 2
Attribute Data (bytes) = 8

BOUNDARY

STATISTICS

Xmin =
Xmax =
Ymin =
Ymax =

Projection
Zone
Datum
Units

Parameters:
Grid:

2792269.645
2867196.652
185845.614
306271.471

Minimum Value =
Maximum Value =
Mean	=

Standard Deviation =

0.000
1.000
0.009
0.094

COORDINATE SYSTEM DESCRIPTION

STATEPLANE

5376

NAD27

FEET Spheroid CLARKE1866

The HELP Command

•	Invokes ArcDOC, the on-line ARC/INFO documentation.

•	Usage: HELP

ฉ 1995 A.C.T. GIS, Inc.

Page 16

-------
GRID Training Course	September 16. 1995

GRID Commands (Continued)

The INFO Command

•	Starts the INFO subsystem from within GRID.

•	Usage: INFO {info_directory}

The KILL Command

•	Deletes a grid.

•	Usage: KILL  {ARC I INFO I ALL}

•	KILL may be executed from both the Arc: and Grid: prompts.

The LISTCOVERAGES Command
ฎ Lists the coverages present in a workspace.

•	Usage: LISTCOVERAGES {workspace}

•	LISTCOVERAGES may be executed from the Arc: and Grid:
prompts.

The LISTGRIDS Command

•	Lists the grids present in a workspace.

•	Usage: LISTGRIDS {workspace}

•	LISTGRIDS may be executed from the Arc: and Grid: prompts.

The LISTIMAGES Command

•	Lists the images present in a workspace.

•	Usage: LISTIMAGES {workspace} {NOFORMAT I FORMAT}

•	LISTIMAGES may be executed from the Arc: and Grid: prompts.

•	{NOFORMAT I FORMAT} specifies whether the image formats
are listed. By default, no formats are listed.

ฉ 1995 A.C.T. GIS, Inc.	Page 17

-------
ft RID Training Course	September 16. 1995

GRID Commands (Continued)

The LISTSTACKS Command

•	Lists the grid stacks present in a workspace.

•	Usage: LISTSTACKS {workspace}

•	LISTSTACKS may be executed from the Arc: and Grid: prompts.

The LOG Command

•	Lists the contents of a LOG file or adds a new entry to the LOG.

•	Usage: LOG  {LIST I ADD}

•	LOG * displays the workspace LOG file.

•	{LIST} is the default. The LOG file is listed. {ADD} allows a
comment line to be added to the LOG file. The user is prompted:

Enter comment line:

Simply enter the desired comment and press .

The PRINTDOC Command

•	Invokes the ArcDOC Print Tool menu which allows any portion
of ArcDOC to be selected and printed.

•	Usage: PRINTDOC

The PROIECTCOMPARE Command

•	Sets the level of comparison between projection files for the
current session.

•	Usage: PROJECTCOMPARE 

•	 means projection aren't compared. {PARTIAL} means
at least one projection file must be defined. {FULL} means both
projection files must be defined identically.

ฉ 1995 A.C.T. GIS, Inc.

Page 18

-------
GRID Commands (Continued)

The QUIT Command

•	Stops execution of GRID and returns the user to the Arc:
prompt.

•	Usage: QUIT

The RENAME Command

•	Renames a grid or other ARC/INFO geo_dataset.

•	Usage: RENAME  

•	RENAME may be executed from the Arc: and Grid: prompts.

The USAGE Command

•	Returns the usage of an GRID command or function.

•	Usage: USAGE 

The VERIFY Command

•	Sets the automatic verification of answers to system prompts.

•	Usage: VERIFY 

•	 means an error message will be returned and the
process will terminate.

•	 prompts for verification to delete or overwrite protection
on data.

•	 means data will be deleted or overwritten without the
user being prompted for verification.

ฉ 1995 A.C.T. GIS, Inc.

Page 19

-------
A.





The GRID Analysis Environment

The following GRID commands are used to set the GRID analysis
environment:

J

/)H

The SETCELL Command ^ ^



\> r .< r

' \	^ V

c?

\

•	Sets the cell size of the current analysis environment.

•	Usage: SETCELL {MAXOF I MINOF I cellsize I grid}

•	{MAXOF} is the default. J It sets the cell size to the maximum of
all inputs.

•	{MINOF} sets the cell size to the minimum of all inputs.

•	{cellsize} sets the cell size to a real number in map units.

•	{grid} sets the cell size to cell size of an existing grid.

•	All GRID functions and operators respect the set cell size.

•	Use the Grid: SHOW SETCELL command to list the current cell
size.

The Shi WINDOW Command

•	Sets the window of the current analysis environment.

•	Usage: SETWINDOW 

Usage: SETWINDOW 

{snap_grid}

•	 sets the window to the maximum of all inputs.

•	 sets the window to the minimum of all inputs.

•	 sets the window to the extent of a grid.

•	 sets the window to the extent of a cover.

•	 sets the window to a specified box
in map units.

ฉ 1995 A.C.T. GIS, Inc.

Page 20

-------
GRID Training Course

September 16. 1995

The GRID Analysis Environment (Continued)

The SETWINDOW Command (Continued)

•	{snap_grid} is a grid that serves as the base for snapping corner
coordinates. It is used with the 
option to ensure that a subset area will match accurately with
the original grid. The window is snapped to the closest lower
left cell and closest upper right cell in {snap_grid}.

•	A graphics window must be active using DISPLAY to use the *
option.

• The window is for analysis purposes only. It is not a display
window and does not affect the display of grids.

A) • Use the Grid: SHOW SETWINDOW command to list the current
y\ SETWINDOW setting.

The SETMASK Command

•	Sets the mask of the current analysis environment.

•	Usage: SETMASK 

•	OFF turns off the use of a mask.

•	 is the name of a grid used as a mask.

•	A mask allows processing to be performed only for cells in the
analysis window overlapped by the mask grid.

•	The SELECTO function can be used to select all cells which will
serve as a mask. Cells should be assigned NODATA where
processing should not occur. The SELECTO functions sets all
unselected cells to NODATA.

ฉ 1995 A.C.T. GIS, Inc.	Page 21

-------
GRID Training Course		—.	September 16.1995

The GRID Analysis Environment (Continued)

The RESTORE Command

•	Restores the analysis environment to the settings in an
environment file.

•	Usage: RESTORE 

The SAVE Command

•	Saves the current analysis environment to a file.

•	Usage: SAVE 

•	The  is an ASCII text file.

The RESET Command

•	Reinitializes the GRID analysis environment to the defaults.

•	Usage: RESET

The SHOW Command

•	Lists the current setting of the user workspace.

•	Usage: SHOW 

•	Commands which are arguments for SHOW in GRID are
ABBREVIATIONS, PROJECTCOMPARE, SCALAR
/ SETCELL, SETMASK, SETWINDOW, and
VERIFY.

The STATUS Command

•	Shows the status of the current analysis environment.

•	Usage: STATUS

•	Displays the current settings for cell size, window, mask, and
abbreviations.

ฉ 1995 A.C.T. GIS, Inc.

Page 22

-------
GRID Trainin9 Course

September 16. 1995

Creating GRID Data

Grid Conversion Basics

•	The main source for GRID data is existing ARC/INFO
coverages.

•	DXF files and IGDS files can be converted to coverages, thus
serving as another source for GRID.

•	DTED, ADRG, images, and DEMs may also be converted
directly to GRID.

•	The main factors to consider when converting data is GRID is
cell resolution, georeferencing images, and the coverage item
used to define cell values.

•	Cell size should be determined from input data resolution, the
resulting database size and disk capacity, the desired response
time since large grids take longer to process, and the types of
analysis to be performed.

•	A cell size finer that the resolution will not produce more
accurate results.

•	Since all grids must be in the same projection to be analyzed
together, grids and lattices may be projected with the PROJECT
command. Images may be georeferenced using the
CONTROLLPOINTS, WARP, and ADJUST commands.

•	Grids may also be converted to images, DEMs, or coverages.

ARC Grid Conversion Commands

•	The following ARC commands can be used to convert coverages
into grids:

ฉ1995 A.C.T. GIS, Inc.

Page 23

-------
GRID Training Course

September 16. 1995

Creating GRID Data (Continued)

The ARC ASCIIGRID Command

•	Converts an ASCII file to a grid.

•	Usage: ASCIIGRID   {INT I FLOAT}

•	 must contain header information consisting of a
set of keywords, followed by cell values in a row-major order.
The file format required is:

cncols xxx>
cnrows xxx>



{nodata_value xxx}

rowl

row2

row n

where xxx is a number, the keyword nodata_value is optional
and defaults to -9999. Row 1 of the grid is at the top of the grid,
row 2 is just below, and so on. Cell values are delimited by
spaces. The number of columns in the header is to determine
where a new row begins.

• The number of cell values must be equal to the number of rows
times the number of columns, or an error will be returned.

ฉ 1995 A.C.T. GIS, Inc.

Page 24

-------
Creating GRID Data (Continued)

The ARC ADRGGRID Command

•	Converts Arc Digitized Raster Graphics (ADRG) image data into
a grid.

•	Usage: ADRGGRID   {in_band}

{ALL I BOX} {xmin} {ymin} {xmax} [ymax}

•	{in_band} is an optional image band number. Band 1 is red, 2 is
green, and 3 is blue.

•	{ALL I BOX) {xmin} {ymin} {xmax} [ymax} are keywords used to
specify if the entire image or a portion of the image is to be
converted.

The ARC DEMLATTICE Command

•	Converts a DEM in USGS or TAME format to a lattice.

•	Usage: DEMLATTICE   {USGS I TAME} {z_factor}

•	{USGS} specifies the DEM is in USGS 7.5 minute, 1 degree, or
other file in USGS DEM format.

•	{TAME} specifies the DEM is in the Terrain Access Made Easy
(TAME) format, the standard format for SPOT DEM data.

•	{z_factor} is the number of ground x,y units in 1 surface ZUNIT.
The ZUNIT value is multiplied by the {z_factor} to adjust the
out_lattice to some other unit of measure (possibly to convert
from feet to meters or vice versa).

•	A lattice is implemented as a point grid.

•	USGS DEMs are not immediately suitable for volume, slope, or
visibility analysis because the x,y locations are stored in latitude
and longitude and the z values are measured in meters. To
convert the z values to feet, use a {z_factor} of 3.280833, and/or
PROJECT the lattice to the desired projection.

ฉ 1995 A.C.T. GIS, Inc.

Page 25

-------
GRID Training Course	September 16. 1995

Creating GRID Data (Continued)

The ARC DTEDGRID Command

•	Converts a US DMA DTED file into a grid.

•	Usage: DTEDGRID 

•	 is the United States Defense Mapping Agency
Digital Terrain Elevation file.

•	At latitudes greater than 50 degrees, the DTED data is no longer
square cells. The data is resampled using bilinear interpolation
to create square grid cells.

•	The Y,X column/row orientation of the DTED data is converted
to the row/column (X,Y) format for grid.

•	DTED data is published in decimal degrees and the vertical unit
of measure is meters.

The ARC FLOATGRID Command

•	Converts a file of binary floating point numbers into a grid.

•	Usage: FLOATGRID  

•	 is an IEEE floating point format, 32 bit signed binary
file.

•	An ASCII .hdr header file is required in addition to the
binary data file.

ฉ 1995 A.C.T. GIS, Inc.

Page 26

-------
GRID Training Course	September 16. 1995

Creating GRID Data (Continued)

The ARC IMAGEGRID Command

•	Converts an image into a grid or set of grids.

Usage: IMAGEGRID   {out_colormap._file} {in_band}
{NEAREST I BILINEAR I CUBIC} {DEFAULT I SQUARE}

•	 can be a BIL, BIP, BSQ, ERDAS, IMAGINE,
GRASS, RLC, SUNRASTER, ADRG, or TIFF image.

•	{out_colormap_file} is an ASCII colormap file created for
pseudocolor images.

•	{in_band} is the optional band number.

•	{NEAREST} is the nearest neighbor resampling algorithm. It
calculates the value of the output cell by assigning it the value
of the nearest pixel in the input image. This is the default.

•	{BILINEAR} is the bilinear interpolation resampling algorithm.
It calculates the value of the output cell by interpolating from
the values of the four nearest pixels in the input image based
upon the weighted distance to these pixels.

•	{CUBIC} is the cubic convolution resampling algorithm. It
calculates the value of each output cell in the same manner as
bilinear, except that the weighted values of the 16 nearest pixels
in the input image are used.

•	{DEFAULT} means the output grid is optimized for use with
GRID.

•	{SQUARE} means the output grid is optimized for use with
ARCSCAN.

ฉ 1995 A.C.T. GIS, Inc.

Page 27

-------
GRID Training Course

September 16. 1995

Creating GRID Data (Continued)

The ARC LINEGRID Command

•	Creates a grid from line features in an ARC/INFO coverage.

•	Usage: LINEGRID   {value_item}

{lookup_table} {weight_table}

•	{value_item} is an item in the coverage AAT used to assign codes
to the grid. By default the internal arc number will be used.
The item must be numeric.

•	{lookup_table} is an INFO table used to define grid cell values.
The table must contain the items {value_item} and CODE.
CODE must be defined as numeric. The table must be sorted in
ascending order on {value_item}.

•	{weight_table} is an INFO table used to assign weights to grid
cell codes. These weights are used to resolve cases when a
single cell can have several possible values. The table must
have two items: CODE and WEIGHT. Both items must be
defined as numeric data types. The CODE with the highest
WEIGHT will be assigned to the cell. If a CODE is not present,
a weight of 0 is assigned.

•	LINEGRID has two prompts. The first is:

Cell Size (square cell):

This is the cell size in map units. The second prompt is:

Convert the Entire Coverage (Y/N)? :

Enter Y or N. If N is entered, the additional prompts are:

Grid Origin (x,y):

Enter the x,y coordinate of the origin in map units.

Then the following prompt appears:

Grid Size (nrows, ncolumns):

Enter the number of rows and columns of cells.

Background value (NODATA/ZERO):

Enter the value of cells not overlaying line features in the grid.

ฉ 1995 A.C.T. GIS, Inc.

Page 28

-------
GRID Training Course	September 16,1995

Creating GRID Data (Continued)

• A samples execution of LINEGRID follows:

Arc: linegrid

Usage: LINEGRID   {value_item} {lookup_table}
{weight_table}

Arc: linegrid railroadl railgrid railroad-code

Converting arcs from railroadl to grid railgrid

Cell Size (square cell): [SQRT 43560]

Convert the Entire Coverage(Y/N)?: y

Enter background value (NOD AT A I ZERO): zero

Number of Rows = 577

Number of Columns = 359

Percentage of Gridded Cells...100%

Arc: describe railgrid

Description of Grid /ACT/RIDDLE/FORESITE/WORK1/RAILGRID

Cell Size	= 208.710 Data Type:	Integer

Number of Rows = 577 Number of Values = 2
Number of Columns = 359 Attribute Data (bytes) = 8

BOUNDARY	STATISTICS

Xmin =	2792269.645 Minimum Value = 0.000

Xmax =	2867196.652 Maximum Value = 1.000

Ymin =	185845.614 Mean	= 0.009

Ymax =	306271.471 Standard Deviation = 0.094

COORDINATE SYSTEM DESCRIPTION

Projection STATEPLANE
Zone	5376

Datum	NAD27

Units	FEET Spheroid CLARKE1866

Parameters:
Arc:

The ARC MOSSGRID Command

•	Creates a grid from a MOSS raster export file.

•	Usage: MOSSGRID  

ฉ 1995 A.C.T. GIS, Inc.

Page 29

-------
GRID Training Course			September 16. 1995

Creating GRID Data (Continued)

The ARC POINTGRID Command

•	Creates a grid from point features in an ARC/INFO coverage.

•	Usage: POINTGRID   {value_item}

{lookup_table} {weight_table}

•	{value_item} is an item in the coverage PAT used to assign codes
to the grid. By default, the internal point number will be used.
The item must be numeric.

•	{lookup_table} is an INFO table used to define grid cell values.
The table must contain the items {value_item} and CODE.
CODE must be defined as numeric. The table must be sorted in
ascending order on {value_item}.

•	{weight_table} is an INFO table used to assign weights to grid
cell codes. These weights are used to resolve cases when a
single cell can have several possible values. The table must
have two items: CODE and WEIGHT. Both items must be
defined as numeric data types. The CODE with the highest
WEIGHT will be assigned to the cell. If a CODE is not present,
a weight of 0 is assigned.

•	POINTGRID has two prompts. The first is:

Cell Size (square cell):

This is the cell size in map units. The second prompt is:

Convert the Entire Coverage (Y/N)? :

Enter Y or N. If N is entered, the additional prompts are:

Grid Origin (x,y):

Enter the x,y coordinate of the origin in map units.

Then the following prompt appears:

Grid Size (nrows, ncolumns):

Enter the number of rows and columns of cells.

Background value (NODATA/ZERO):

Enter the value of cells not overlaying point features in the grid.

ฉ 1995 A.C.T. GIS, Inc.

Page 30

-------
GRID Training Course

September 16. 1995

Creating GRID Data (Continued)

The ARC POLYGRID Command

•	Creates a grid from polygon features in an ARC/INFO coverage.

•	Usage: POLYGRID   {value_item}

{lookup_table} {weight_table}

•	{value_item} is an item in the coverage PAT used to assign codes
to the grid. By default, the internal polygon number will be
used. The item must be numeric.

•	{lookup_table} is an INFO table used to define grid cell values.
The table must contain the items {value_item} and CODE.
CODE must be defined as numeric. The table must be sorted in
ascending order on {value_item}.

•	{weight_table} is an INFO table used to assign weights to grid
cell codes. These weights are used to resolve cases when a
single cell can have several possible values. The table must
have two items: CODE and WEIGHT. Both items must be
defined as numeric data types. The CODE with the highest
WEIGHT will be assigned to the cell. If a CODE is not present,
a weight of 0 is assigned.

•	POLYGRID has two prompts. The first is:

Cell Size (square cell):

This is the cell size in map units. The second prompt is:

Convert the Entire Coverage (Y/N)? :

Enter Y or N. If N is entered, the additional prompts are:

Grid Origin (x,y):

Enter the x,y coordinate of the origin in map units.

Then the following prompt appears:

Grid Size (nrows, ncolumns):

Enter the number of rows and columns of cells.

Background value (NODATA/ZERO):

Enter the value of cells not overlaying polygon features in the grid.

ฉ 1995 A.C.T. GIS, Inc.

Page 31

-------
GRID Training Course	September 16. 199$

Creating GRID Data (Continued)

The ARC SVFGRID Command

•	Converts an ARC/INFO single variable file into a grid.

•	Usage: SVFGRID    
 

•	 is the single variable file to be converted. SVF
files were the grid files from ESRI's original PIOS and GRID
software from the 1980's.

•	 and  are the x and y coordinate of the lower left
corner of the SVF file in map units.

o  is the cell width of the SVF file in map units.

•	 is the cell height of the SVF file in map units.

•	If the cell width and cell height are different, the SVF is
resampled to create square grid cells.

•	Only integer grids may be created with the SVFGRID command.

The ARC TOPOGRID Command

•	Generates a hydrologically correct grid of elevation from point,
line, and polygon coverages.

•	Usage: TOPOGRID  

•	 is the cell size of the output grid in map units.

•	The TOPOGRID command is similar to PROJECT and provides
a TopoGrid: prompt.

•	Various subcommands are available at the TopoGrid: prompt.
These are:

•	BOUNDARY  which is a polygon coverage that
defines the boundary of the output grid.

ฉ 1995 A.C.T. GIS, Inc.

Page 32

-------
GRIDTraininn Course	 September 16. 1995

Creating GRID Data (Continued)

The ARC TOPOGRID Command (Continued)

•	COMMANDS {prefix} lists the available subcommands.

•	DATATYPE  is the primary type of input
data.

•	END concludes the specification of subcommands.

•	ENFORCE  turns the drainage enforcement routine
on or off.

•	ITERATIONS  is the maximum number of iterations of
each grid resolution.

•	LIST lists the current setting of all subcommands.

•	MARGIN  is the distance in map units to interpolate the
specified XYZLIMITS. The default is 0.

•	OUTPUTS {sink_cover} {drainage_cover} {diagnostic_file}
provides optional output information that can be used to
evaluate the output elevation grid.

•	POINT   is a point cover representing
surface elevations.

•	QUIT quits the TOPOGRID command without creating output.

•	RESET resets all parameters to their default values.

•	SINK   allows input of a point cover
representing a known topographic depression.

•	STREAM  is line coverage representing streams.

•	TOLERANCES {rms} {toll} {tol2} is a set of tolerances used to
adjust the calculate the drainage enforcement process. The
default tolerances are 0.5, 2.5, and 10.

ฉ 1995 A.C.T. GIS, Inc.

Page 33

-------
GRID Training Course	 September 16.1995

Creating GRID Data (Continued)

The ARC TQPOGRID Command (Continued)

•	XYZLIMITS {xmin} {ymin} {xmax} {ymax} {zmin} {zmax} are the
limits of the input data to be used to create the grid.

•	The TOPOGRIDTOOL is a menu interface for the TOPOGRID
command.

The ARC TOPOGRIDTOOL Command

•	TOPOGRID creates a hydrologically correct digital elevation
model from comparatively small but well selected elevation and
stream coverages. It is based upon the ANUDEM program
developed by Michael Hutchinson.

•	Usage: TOPOGRIDTOOL  

ฉ 1995 A.C.T. GIS, Inc.

Page 34

-------
GRID Training Course	September 16. 1995

Creating GRID Data (Continued)

The = Operator

•	Creates a new output grid from an input grid, scalar, number, or
expression.

•	Usage:  = 

•	 is an output integer or floating point grid. The grid
must not already exist.

•	A generic grid expression would be coutput = result of input>
where result of input may be a mathematical expression or
GRID function.

•	GRID functions perform some type of analysis and create some
type of output, usually a new grid. An expression in the form
 = ) must be
given to save the output of a function to a new grid.

•	 are the list of required and optional
arguments for each function separated by commas.

•	Functions may be nested inside one another. The result of the
innermost function serves as the input for the surrounding
function and so on.

•	A scalar is the current value of a specified scalar variable. A
scalar is a variable in GRID to which a value may be assigned.
Scalars may be used in expressions such as:

outgrid = ingrid + 

GRID Data Creation Functions

•	The following functions are available at the Grid: prompt in
order to convert line, point, and polygon coverages to a grid.

ฉ 1995 A.C.T. GIS, Inc.

Page 35

-------
GRID Training Course

September 16. 1995

Creating GRID Data (Continued)

The LINEGRIDOFunction

•	Creates a grid from line features in an ARC/INFO coverage.

•	Usage: LINEGRID(, {item}, {lookup_table},

{weight_table}, , {NODATA I ZERO})

•	 is the input line coverage.

•	{item} is the an item in the coverage AAT used to assign codes to
the grid. By default, the internal arc number will be used. The
item must be numeric.

•	{lookup_table} is an INFO table used to define grid cell values.
The table must contain the items {item} and CODE. CODE must
be defined as numeric. The table must be sorted in ascending
order on {value_item}.

•	{weight_table} is an INFO table used to assign weights to grid
cell codes. These weights are used to resolve cases when a
single cell can have several possible values. The table must
have two items: CODE and WEIGHT. Both items must be
defined as numeric data types. The CODE with the highest
WEIGHT will be assigned to the cell. If a CODE is not present,
a weight of 0 is assigned.

•	 is the output grid cell size.

•	{NODATA I ZERO} is the background value assigned to cells in
which line features do not exist.

ฉ1995 A.C.T. GIS, Inc.

Page 36

-------
GRID Training Course

September 16. 1995

Creating GRID Data (Continued)

The POINTGRIDOFunction

•	Creates a grid from point features in an ARC/INFO coverage.

•	Usage: POINTGRID(, {item}, {lookup_table},

{weigh t_table}, / {NODATA I ZERO})

•	 is the input line coverage.

•	{item} is the an item in the coverage PAT used to assign codes to
the grid. By default, the internal point number will be used.
The item must be numeric.

•	{lookup_table} is an INFO table used to define grid cell values.
The table must contain the items {item} and CODE. CODE must
be defined as numeric. The table must be sorted in ascending
order on {value_item}.

•	{weight_table} is an INFO table used to assign weights to grid
cell codes. These weights are used to resolve cases when a
single cell can have several possible values. The table must
have two items: CODE and WEIGHT. Both items must be
defined as numeric data types. The CODE with the highest
WEIGHT will be assigned to the cell. If a CODE is not present,
a weight of 0 is assigned.

•	 is the output grid cell size.

•	{NODATA I ZERO} is the background value assigned to cells in
which point features do not exist.

ฉ 1995 A.C.T. GIS, Inc.

Page 37

-------
GRID Training Course

September 16. 1995

Creating GRID Data (Continued)

The POLYGRIDOFunction

•	Creates a grid from polygon features in an ARC/INFO coverage.

•	Usage: POLYGRID(/ {item}, {lookup_table},

{weight_table}, )

•	 is the input line coverage.

•	{item} is the an item in the coverage PAT used to assign codes to
the grid. By default, the internal polygon number will be used.
The item must be numeric.

•	{lookup_table} is an INFO table used to define grid cell values.
The table must contain the items {item} and CODE. CODE must
be defined as numeric. The table must be sorted in ascending
order on {value_item}.

•	{weight_table} is an INFO table used to assign weights to grid
cell codes. These weights are used to resolve cases when a
single cell can have several possible values. The table must
have two items: CODE and WEIGHT. Both items must be
defined as numeric data types. The CODE with the highest
WEIGHT will be assigned to the cell. If a CODE is not present,
a weight of 0 is assigned.

•	 is the output grid cell size.

ฉ 1995 A.C.T. GIS, Inc.

Page 38

-------
GRID Training Course

September 16. 1995

Displaying Grids

GRID Display Overview

•	Displaying grids is much like displaying coverages. Arcplot
commands are available from the Grid: prompt which allows
grids to be displayed and hardcopy output to be generated with
having to leave the GRID module.

•	It is assumed that users are familiar with the display, query, and
hardcopy map generation capabilities of Arcplot. There are
simply a few new commands which are needed for specifically
displaying grids in Arcplot or GRID.

•	The DISPLAY device must be define before a grid can be
displayed.

•	The MAPEXTENT must be set to one or more grids before a grid
can be displayed.

Grid Cell Value Transformation

•	There are two concepts for displaying grids.

1.	Grid values can be transformed through stretching or the
use of a remap table.

2.	Transformed grid cell values can be passed to a shadeset
or an ASCII colormap file which specifies the color
associated with each transformed cell value.

•	A cell value transformation is graphical and does not change the
actual grid.

•	To display a grid, the cell values can be transformed either
through a stretch or reclassification. Cell values are converted
into symbol numbers.

•	If cell values are equal to symbol number values in a shadeset,
no transformation is needed. Invoke GRID and try the
following example:

ฉ 1995 A.C.T. GIS, Inc.

Page 39

-------
GRID Training Course	September 16, 1995

Displaying Grids (Continued)

Grid Cell Value Transformation (Continued)

Grid: arc generate gridcovl6
Generate: fishnet

Fishnet Origin Coordinate (X,Y): 0,0
Y-Axis Coordinate (X,Y): 0,4
Cell Size (Width,Height): 1,1
Number of Rows, Columns: 4,4
Generate: quit
Externalling BND and TIC...

Grid: arc build gridcovl6 poly
Building polygons-
Grid: disp 9999 3
Grid: polygrid

Usage: (*) POLYGRID(,{item},{lookup_table},{weight_table},{cellsize})
Grid: setcell 1

Grid: gridl6 = polygrid(gridcovl6, gridcovl6-id)

Converting polygons from GRIDCOV16 to grid GRID16

Number of Rows - 4

Number of Columns = 4

Percentage of Gridded Cells...100%

Grid: mape gridl6

Grid: shadeset color

Grid: gridpaint gridl6

Grid: arclines gridcovl6 1

Grid: polygontext gridcovl6 gridcovl6-id

Grid:

• In this example/ a 4x4 polygon coverage is generated with
GENERATE, and topology created with BUILD. Within GRID,
the coverage is converted to a grid using the POLYGRIDO
function using the cover-id's as cell values. Then the grid is
drawn with the GRIDPAINT command using SHADESET
COLOR. The cells are shaded with each symbol in
COLOR.SHD. In this example, no transformation of cell values
is needed.

ฉ 1995 A.C.T. GIS, Inc.

Page 40

-------
GRID Training Course			September 16. 1995

Displaying Grids (Continued)

Grid Cell Value Transformation (Continued)

•	Stretching of cell values is commonly done to continuous grids
such as an elevation surface in order to display elevations as
continuous shades of gray. Values are stretched from 0 to 255.

•	Two types of stretches are linear and equal-area.

•	A linear stretch rescales the cell values from their original range
to a range from 0 to 255 (which is the maximum number of
colors that can be simultaneously displayed on an 8-bit color
device).

•	An equal-area stretch also rescales the cell values from 0 to 255,
but the difference is that the values are distributed so that an
equal number of cells are assigned to each of the 256 possible
values. An equal-area stretch requires a VAT and thus cannot
be used with floating point grids.

•	The HISTOGRAM command can be used to view a graph
indication the frequency distribution of values in a GRID. The
DESCRIBE command can be used to determine the range of cell
values (Minimum and maximum). If working with an integer
grid, the VAT can be displayed with LIST to see exactly what
the cell values are as well as their frequency.

The HISTOGRAM Command

•	Displays the frequency distribution of values in a grid.

•	Usage: HISTOGRAM  {item} {n_levels}

{max_count} {zone_grid}

•	The DISPLAY device must be defined.

•	 is the grid whose values the frequency will be
displayed for.

ฉ 1995 A.C.T. GIS, Inc.

Page 41

-------
GRID Training Course	September 16, 1995

Displaying Grids (Continued)

The HISTOGRAM Command (Continued)

•	{item} is the item in the VAT the frequency will be displayed
for. A # should be used if the grid is floating point.

•	{n_levels} is the number of intervals to be used when
reclassifying a floating point grid to integer.

•	{max_count} is the maximum frequency along the Y axis.

•	The example below illustrates the output from HISTOGRAM
for a grid called MAP11:

MAPI 1

Remap Tables

•	Remap tables can also be used to reclassify grid data for display.

•	A remap table may be either an INFO table or an ASCII file.

•	A remap table has two parts:

1.	A cell value to be reclassed

2.	The reclassified value.

ฉ 1995 A.C.T. GIS, Inc.

Page 42

-------
GRID Training Course

September 16.1995

Displaying Grids (Continued)

Remap Tables (Continued)

•	A remap table for a grid is much like a lookup table is used to
display coverage features.

•	For integer grids, any numeric item in the VAT may be
remapped. For floating point grids, VALUE must be used since
there are no additional items to reference.

•	An INFO remap table consists of two items, the VAT numeric
item to remap and the item SYMBOL to store the remapped
symbol. The table must be sorted in ascending order on the VAT
item being reclassed.

•	When an INFO remap table is used, if a value is not located, the
next highest value in the remap table will be used just like
ranges are handled for lookup tables.

•	An ASCII remap table consists of comments, optional keywords,
and assignment statements.

•	Comments are descriptive text strings to describe the remap
table. Comments can appear anywhere and must begin with a
pound sign (#).

•	Two optional keywords are LOWEST-INPUT and LOWEST-
OUTPUT and must appear above the assignment statements.
LOWEST-VALUE  is used to identify the lowest cell
value in the grid to reclassify. LOWEST-OUTPUT  is
used to identifies the starting reclass value (if not specified the
default is 1).

ฉ 1995 A.C.T. GIS, Inc.

Page 43

-------
GRID Training Course

September 16. 1995

Displaying Grids (Continued)

Remap Tables (Continued)

• The assignment statements assign an output value to a specified
input cell value or range of values. The assignment statement
can be defined in several ways. These are:

1.	Value alone - The reclass value is determined from the
LOWEST-OUTPUT value (which must be specified). The
first input value is assigned the value of the LOWEST-
OUTPUT value, the second input value is assigned the
value of LOWEST-OUTPUT value + 1, and so on. For
example:

#	Example 1 Remap Table
lowest-input 3
lowest-output 2

5

6

7
15

Input values less than 3 are assigned a reclass value of
NODATA. An input value >= 3 and <= 5 are assigned a
reclass value of 2. An input value of > 5 and <= 6 are
assigned a reclass value of 3. An input value of > 6 and
<= 7 are assigned a reclass value of 4. An input value > 7
and <= 15 are assigned a reclass value of 5. All cell values
> 15 are assigned a reclass value of NODATA. If
LOWEST-INPUT were omitted, all cell values less than 5
would have been reclassed as NODATA.

2.	Ranges - Explicit ranges are specified. For example:

#	Example 2 Remap Table
lowest-output 2

3 5
5 9
13 15

ฉ 1995 A.C.T. GIS, Inc.

Page 44

-------
GRID Training Course

September 16.1995

Displaying Grids (Continued)

Remap Tables (Continued)

Input values less than 3 are assigned a reclass value of
NODATA. Cell values >= 3 and <= 5 are assigned a reclass
value of 2. Cell values > 5 and <= 9 are assigned a reclass
value of 3. Cell values > 9 and <= 13 are assigned
NODATA. Cell values > 13 and <= 15 are assigned a
reclass value of 4. Cell values > 15 are assigned NODATA.

3.	User-specified output values - An additional field may be
added to the remap table. The input cell value and range
value are followed by a colon (:) and then the reclass value.
For example:

#	Example 3 Remap Table
lowest-input 3

5:10
6:16
7:62
15:28

Input values less than 3 are assigned a reclass value of
NODATA. Cell values >= 3 and <= 5 are assigned a reclass
value of 10. Cell values > 5 and <= 6 are assigned a reclass
value of 16. Cell values > 6 and <= 7 are assigned a value
of 62. Cell values > 7 and <= 15 are assigned a reclass value
of 28. Cell values > 15 are assigned NODATA.

4.	Explicit input ranges and user-specified output - Same as
example 3 but input value ranges are specified. For
example:

#	Example 4 Remap Table
3 5:9

5 9:8
13 15:59

ฉ 1995 A.C.T. GIS, Inc.

Page 45

-------
GRID Training Course

September 16. 1995

Displaying Grids (Continued)

Remap Tables (Continued)

Input values less than 3 are assigned a reclass value of
NODATA. Cell values >= 3 and <= 5 are assigned a reclass
value of 9. Cell values > 5 and <= 9 are assigned a reclass
value of 8. Cell values > 9 and <= 13 are assigned
NODATA. Cell values > 13 and <= 15 are assigned a
reclass value of 59. Cell values > 15 are assigned
NODATA.

Colormap Files

•	A colormap file is an ASCII file of color index numbers and
their corresponding RGB values.

•	A colormap file should be in the format:

index_number red green blue
For example:

10	0	0

2	255	0	0

3	0	255	0

4	0	0	255

•	A colormap file should be sorted in ascending order on the
device index number.

•	Pseudocolor 8-bit display devices can only display 256 colors at
one time. Pseudocolor devices use a device colormap to
determine which colors will be assigned to pixel values on the
screen. The device colormap contains colorcells that define the
red, green, and blue color components for a given pixel value.
Over 16.7 (256x256x256) colors are possible, but only 256 may be
used at any one time.

ฉ 1995 A.C.T. GIS, Inc.

Page 46

-------
GRID Training Course

September 16. 1995

Displaying Grids (Continued)

Colormap Files (Continued)

•	When ARC/INFO requests a color be drawn on the screen, that
color is loaded into the device colormap.

•	In order to give the user control over how images and grids are
displayed, the display colormap is divided into static and
dynamic colorcells. Static colorcells are loaded with predefined
colors (n red, n green, and n blue colors). Dynamic colorcells are
temporary colors that are defined and allocated as needed.

•	By default, ARC/INFO creates a display colormap that contains
only static colorcells. If there are 216 static colorcells (6 levels
of red, 6 levels of green, and 6 levels of blue), there are 6
possible shades of gray. However, the eye can interpret about 20
shades of gray. For this reason, it is often useful to create
dynamic colorcells to enable images and grids to be displayed
with a more varying number of shades.

•	The DISPLAY COLORMAP  
command can be used to specify the total number of colorcells
to allocation and the number of static colorcells. The difference
in the number of static colors and the specified total will be the
number of dynamic colors available.

•	The COLOR command can be used to redefine color component
values of the specified hardware device index. Its usage is
COLOR  . Device indexes 0
through 7 may always be redefined. Otherwise, a device index
greater than 7 should be used to define a dynamic color.

ฉ 1995 A.C.T. GIS, Inc.

Page 47

-------
GRID Training Course	September 16. 1995

Displaying Grids (Continued)

GRID Display Commands

The following commands are used to display grids in Arcplot:

The GRIDNODATASYMBOL Command

•	Sets the shade symbol or colormap index for displaying grid
cells with NODATA values.

•	Usage: GRIDNODATASYMBOL 

•	Usage: GRIDNODATASYMBOL TRANSPARENT

•	Usage: GRIDNODATASYMBOL  {SPOT }

•	Usage: GRIDNODATASYMBOL  

{SPOT }

•	 is the shade symbol or colormap
index used to display cells with a value of NODATA.

•	TRANSPARENT denotes that NODATA will be displayed
transparently.

•	 {SPOT } is the colorname and optional spot
percentage to display NODATA cells. Colornames are stored in
stored in $ARCHOME/symbols/colorfile (an ASCII file).

•	  {SPOT } is a color
model, its parameters, and optionally a spot percentage used to
display cells assigned NODATA.

•	Arcplot and GRID support five color models. These are:

1.	HSV - hue saturation value

2.	HLS - hue lightness saturation

3.	RGB - red green blue

4.	CMY - cyan magenta yellow

5.	CMYK - cyan magenta yellow black

ฉ1995 A.C.T. GIS, Inc.

Page 48

-------
GRID Training Course

September 16. 1995

Displaying Grids (Continued)

The GRIPPAINT Command

•	Displays a grid using the specified item value, stretch, or remap
table and a colormap file.

•	Usage: GRIDPAINT  {item}

{IDENTITY I LINEAR I EQUALAREA I remap_table}

{WRAP I NOWRAP} {NOMINAL I GRAY I colormap_file}

•	 is the grid to display.

•	{item} is an item in the VAT. If no item is specified, the default
is VALUE. The item must be numeric.

•	{IDENTITY} is the default. It means no stretch is applied and
the cell value will be used as the shade symbol.

•	{ LINEAR} means a linear stretch will be applied. Values are
stretched from 0 to 255.

•	{EQUALAREA} means an equal-area stretch will be applied.
Values are stretched from 0 to 255.

•	{remap_table} means a remap table will be used to determine
the symbol to be used to display each cell value.

•	{WRAP} means the values in the colormap will be repeated to
fulfill the range of values required by the grid. This is the
default.

•	{NOWRAP} means the values in the colormap file will not be
repeated. Values outside the colormap range will be displayed
as NOD ATA cells.

•	{NOMINAL} means that sixteen colors will be used to display
the grid. This is typically used to display integer grids.

•	{GRAY} means that 256 symbols with values from 0 to 255 will
be used. This is typically used to display floating point grids.

•	{colormap_file} an ASCII file of index numbers and RGB values
used to display a grid.

ฉ 1995 A.C.T. GIS, Inc.

Page 49

-------
GRID Training Course

September 16.1995

Displaying Grids (Continued)

The GRIDSHADES Command

•	Shades a grid using the specified item value, stretch, or remap
table to determine color from the current shadeset.

•	Usage: GRIDSHADES  {item}

{IDENTITY I LINEAR I EQUALAREA I remap_table}

{WRAP I NOWRAP}

•	 is the grid to display.

•	{item} is an item in the VAT. If no item is specified, the default
is VALUE. The item must be numeric.

•	{IDENTITY} is the default. It means no stretch is applied and
the cell value will be used as the shade symbol.

•	{ LINEAR} means a linear stretch will be applied. Values are
stretched from 0 to 255.

•	{EQUALAREA} means an equal-area stretch will be applied.
Values are stretched from 0 to 255.

•	{remap_table} means a remap table will be used to determine
the symbol to be used to display each cell value.

•	{WRAP} means the values in the colormap will be repeated to
fulfill the range of values required by the grid. This is the
default.

•	{NOWRAP} means the values in the colormap file will not be
repeated. Values outside the colormap range will be displayed
as NODATA cells.

•	The SHADECOLORRAMP command in Arcplot can be used to
create ramps of continuous colors suitable for display of ordinal
and surface data.

•	Only the color component of the shadeset is used in displaying
the values of a cell.

ฉ 1995 A.C.T. GIS, Inc.

Page 50

-------
GRID Training Course 			Septeprcbgr 16, 1995

Displaying Grids (Continued)

The GRIPCOMPOSITE Command

•	Displays three grids as a composite image.

•	Usage: GRIDCOMPOSITE   

{IDENTITY I LINEAR I EQUALAREA}

•	Usage: GRIDCOMPOSITE   

{IDENTITY I LINEAR I EQUALAREA}

•	 is the grid to be displayed as red.

•	 is the grid to be displayed as green.

•	 is the grid to be displayed as blue.

•	{IDENTITY} is the default. It means no stretch is applied and
the cell value will be used as the shade symbol.

•	{ LINEAR} means a linear stretch will be applied. Values are
stretched from 0 to 255.

•	{EQUALAREA} means an equal-area stretch will be applied.
Values are stretched from 0 to 255.

•	 is the grid to be displayed as hue.

•	 is the grid to be displayed as saturation.

•	 is the grid to be displayed as value.

•	GRIDCOMPOSITE can be used for displaying multi-band
images converted to grid.

ฉ 1995 A.C.T. GIS, Inc.

Page 51

-------
GRID Training Course			September 16.1995

Displaying Grids (Continued)

The GRIPDIRECTION Command

•	Draws arrows whose direction is determined by the value of the
grid cells.

•	Usage: GRIDDIRECTION  {sample_interval}

{NORTH I EAST I SOUTH I WEST}

{CLOCK I COUNTERCLOCK} {reference_value}

{degree_step}

•	 is the grid to be displayed with arrows.

•	{sample_interval} is the number of cells in the grid's x and y
direction that will be sampled to produce a single arrow, the
nearest neighbor value to the center of the sample will be used
as the direction for the sample. The default is 1.

•	{NORTH I EAST I SOUTH I WEST} is the direction of the
reference value. The default is NORTH.

•	{CLOCK I COUNTERCLOCK} is the direction in which to
increment. CLOCK is the default.

•	{reference_value} is the starting value for the specified direction.
The default is 0.

•	{degree_step} the step interval for incrementing to the next
direction. The default is 1. This can be determined by dividing
the range of values by 360.

•	The values for the input grid should represent a continuous
range of direction.

ฉ 1995 A.C.T. GIS, Inc.

Page 52

-------
GRID Training Course	September 16, 1995

Displaying Grids (Continued)

The GRIDNET Command

•	Draws a fishnet or mesh of lines delineating the boundaries of
cells in a grid, or the boundary of a grid.

•	Usage: GRIDNET  {BND I ALL}

•	 is the name of the input grid.

•	{BND} means the bounding rectangle of the grid is drawn.

•	{ALL} means the boundaries of each cell are drawn.

•	Use the Arcplot line symbol commands to control the line
symbol used to draw the mesh.

The IMAGE Command

•	Draws a raster image or a group of images from an image
catalog.

Usage: IMAGE  {band}

Usage: IMAGE cimage I image_catalog> COMPOSITE

  

Usage: IMAGE  TRANSPARENT



Usage: IMAGE  TRANSPARENT



Usage: IMAGE cimage I image_catalog> TRANSPARENT

 

Usage: IMAGE cimage I image_catalog> OPAQUE

cforeground_shadesymbol> cbackground_shadesymbol>

Usage: IMAGE cimage I image_catalog> OPAQUE

cforeground_colorname> 

Usage: IMAGE cimage I image_catalog> OPAQUE

cforeground_colormodel> cparameters> cbackground_colormodel>
cparameters>

•	A grid may be displayed with the IMAGE command.

ฉ 1995 A.C.T. GIS, Inc.

Page 53

-------
GRID Training Course

September 16. 1995

Displaying Grids (Continued)

The ARCFLOT SHADECOLORRAMP Command

•	Creates shade symbols with a specified color range that replace
the existing shade symbols.

•	Usage: SHADECOLORRAMP  

  {LINEAR I NONLINEAR}

•	 is the first symbol number that the color ramp
will be assigned. Valid numbers are 1 to 999.

•	 is the total number of symbols to be
included in the color ramp. The  number plus
the total number of symbols cannot exceed 500.

•	 is the color used to start the color ramp.

•	 is the color terminating the color ramp.

•	{LINEAR} means the symbols will be evenly distributed along a
straight line in color space. This is the default.

•	{NONLINEAR} means the symbol colors will be determined by
using a curve through color space in order to render a more
aesthetic ramp of well defined and saturated colors.

•	SHADECOLORRAMP uses the current shade symbol to
automatically regenerate shade symbols.

•	 cannot exceed the number of symbols in
the current shadeset.

•	All symbols created by SHADECOLORRAMP will be set to
SHADETYPE COLOR in order to display solid-fill shades.

•	SHADESAVE can be used to save the symbols created by
SHADECOLORRAMP. Before issuing SHADECOLORRAMP,
issue SHADEDELETE ALL and SHADESET  to
load just the one shadeset file into the Arcplot shade symbol
buffer.

ฉ 1995 A.C.T. GIS, Inc.

Page 54

-------
GRID Training Course	 September 16. 1995

Displaying Grids (Continued)

The LOADCOLORMAP Command

•	Loads the colors in an ASCII colormap file into the current
shadeset.

•	Usage: LOADCOLORMAP 

•	 is the name of the input colormap file.

•	The colormap symbol numbers must ranger from 1 to 999.

•	The SHADECOLOR of each symbol is set to the RGB value
from the colormap file.

•	The SHADETYPE for each symbol is set to COLOR.

•	If a shade does not exist, a corresponding index number will be
used to create that symbol number.

•	Use SHADEDELETE ALL then SHADESET 
before using LOADCOLORMAP to ensure that only symbols in
the current shadeset are those corresponding to records in the
colormap file.

The SAVECOLORMAP Command

•	Saves the colors corresponding to symbols in the current
shadeset to an ASCII colormap file.

•	Usage: SAVECOLORMAP 

•	 is the output colormap file.

ฉ 1995 A.C.T. GIS, Inc.

Page 55

-------
GRID Training Course			September 16. 1995

Displaying Grids (Continued)

The CONVERTREMAF Command

•	Converts remap tables from INFO tables to ASCII files or from
ASCII files to INFO tables.

•	Usage: CONVERTREMAP  

{TOINFO I TO ASCII} {value_item} {remap_item}

•	  are the input and output remap
tables.

•	{TOINFO} converts an ASCII remap table to an INFO remap
table.

•	{TOASCII} converts an INFO remap table to an ASCII remap
table.

•	{value_item} is an INFO item whose values are remapped. The
default is VALUE.

•	{remap_item} is an INFO item holding the remapped values.
The default is LINK.

The CREATEREMAP Command

•	Generates a remap table for a grid.

•	Usage: CREATEREMAP  

{PIECEWISE I EQINTERVAL I EQAREA I RECNO}

{nlevels} {lowest_level} {ASCII I INFO} {in_item} {out_item}

•	 is the input grid.

•	 is the output remap table.

•	{PIECEWISE} is a graphic method of piecewise linear mapping.
A histogram of data distribution is drawn and can be
manipulated to redistribute the output data values.

•	{EQINTERVAL} performs an equal interval mapping of the
values in the input grid, stretching the values from 0 to 255.

ฉ1995 A.C.T. GIS, Inc.

Page 56

-------
GRID Training Course	September 16, 1995

Displaying Grids (Continued)

The CREATEREMAP Command (Continued)

•	{EQAREA} performs an equal area mapping of values in the
input grid, stretching the values from 0 to 255.

•	{RECNO} input values are mapped to their corresponding record
number in the VAT.  must be an integer grid.

•	{nlevels} is the number of output values. The default for integer
grids is the number of unique values. For a floating point grid,
the default is 256.

•	{lowest_level} is the lowest output value. The default is 1.

•	{ASCII} indicates an ASCII remap table is created.

•	{INFO} indicates an INFO remap table is created.

•	{in_item} is the name of the input item for an INFO remap table.

•	{out_item} is the output item for an INFO remap table.

•	DISPLAY must be set before using the {PIECEWISE} option.

The REMAPGRID Command

•	A menu-based tool for creating custom remap tables for a grid.

•	Usage: REMAPGRID  {out_remap} {VAT_item}

•	 is the input grid.

•	{out_remap} is the output remap table. The name can be omitted
and entered in the menu.

•	{VAT_item} is the name of the item in  to remap. The
default is VALUE.

•	The menu invoked contains buttons which execute additional
menus for creating a remap table using the options in the
CREATEREMAP command.

ฉ 1995 A.C.T. GIS, Inc.

Page 57

-------
GRID Training Course

September 16. 1995

Displaying Grids (Continued)

The SHADEGRID Command

•	A menu-based tool for generating shade sets and remap tables
that can be used to create a custom display of a grid.

•	Usage: SHADEGRID 

•	SHADEGRID helps the user interactively create the remap
table(s) and shadeset(s) required to display grids.

ฉ 1995 A.C.T. GIS, Inc.

Page 58

-------
GRID Training Course

September 16. 1995

Querying Grids

The CELLVALUE Command

•	Returns the value and value attributes for the cell containing a
specified point.

•	Usage: CELLVALUE   {item...item I NONE}
Usage: CELLVALUE   {NONE I ALL}

•	 is the name of the grid to query.

•	 is the name of the stack to query.

•	 indicates the cell location as an x,y coordinate or
interactive if the * option is used.

•	{item...item} is an optional list of selected items in the VAT to be
listed for the cell. The default is all items in the VAT are
displayed.

•	{NONE} indicates that only the VALUE item in the VAT will be
listed.

•	{ALL} indicates the values for all items in the stack will be
displayed for each selected location.

•	CELLVALUE is comparable to the Arcplot IDENTIFY command
for coverages.

•	If the grid is floating point, VALUE is listed.

ฉ 1995 A.C.T. GIS, Inc.

Page 59

-------
GRID Training Course

September 16. 1995

Querying Grids (Continued)

The GRIDOUERY Command

•	Displays the set of cells in a grid that satisfies a logical
expression using the current shadeset.

•	Usage: GRIDQUERY  {item}

{IDENTITY I LINEAR I EQUALAREA I remap_table}
{WRAP I NOWRAP} 

•	 is the grid to query.

•	{item} is an item in the VAT. If no item is specified, the default
is VALUE. The item must be numeric. If no remap or stretch is
given, then {item} is used as the shade symbol numbers to shade
the polygons.

•	{IDENTITY} is the default. It means no stretch is applied and
the cell value will be used as the shade symbol.

•	{ LINEAR} means a linear stretch will be applied. Values are
stretched from 0 to 255.

•	{EQUALAREA} means an equal-area stretch will be applied.
Values are stretched from 0 to 255.

•	{remap_table} means a remap table will be used to determine
the symbol to be used to display each cell value.

•	{WRAP} means the values in the colormap will be repeated to
fulfill the range of values required by the grid. This is the
default.

•	{NOWRAP} means the values in the colormap file will not be
repeated. Values outside the colormap range will be displayed
as NODATA cells.

•	 is a logical expression which operates on
VALUE and attributes of . Those cells for which the
expression is true are selected and displayed.

ฉ 1995 A.C.T. GIS, Inc.

Page 60

-------
GRID Training Course			September 16. 1995

GRID Terminology

Grid

•	A grid describes features and characteristics of an area and their
relative position in space.

Cell

•	The basic spatial unit in a grid. All cells are square (equal size
in the X and Y dimensions.

Row and Column

•	Cells are arranged in rows and columns which produce a
Cartesian matrix.

Value

•	Each cell in a grid is assigned a value to identify the
characteristics of a cell.

Zone

•	Any two or more cells in the same grid which have the same
value are considered to belong to the same zone. A zone may be
connected or disconnected.

Regions

•	Each group of connected cells in a zone are considered to be a
region.

VAT

•	Integer or categorical grids usually have a value attribute table
(VAT), an INFO table containing the items VALUE (for each
unique cell value) COUNT (a cell count or frequency for each
cell value record), and optional items that further describe each
cell value.

Name

•	Every grid has a filename. Filenames may be 12 characters long.

ฉ 1995 A.C.T. GIS, Inc.

Page 61

-------
GRID Training Course			September 16. 1995

GRID Spatial Processing Concepts

•	The type of grid processing depends on the operator or function
used. Grid function types are local, focal, zonal, and global.

Location Determination

•	GRID stores the origin of a grid and the cell size and map units.
This allows GRID to determine the row-column address using
x- and y-coordinates.

Cell-by-Cell Processing

•	GRID performs all operators and functions (except zonal and
global functions) on a cell-by-cell basis. An operator or function
begins at the upper-left corner of a grid and moves from left to
right and top to bottom of the grid until all cells have been
processed. As a cell is processed, the result is written to the
corresponding row-column address in the output grid.

Multi-grid Calculations

•	Most operators and functions either allow or require multiple
grids as input. All operators and functions process all values
between grids.

Operator and Local Function Processing

•	All operators and local functions perform cell-by-cell
processing.

Neighborhood Processing

•	Focal functions also use cell-by-cell processing, but consider the
values of cells within a neighborhood to determine the output
cell value.

Neighborhood-notation Processing

•	Custom neighborhoods can be defined using neighborhood
notation. The notation is in row-column space and is relative to
the current cell being processed. X,Y offset values are used.
Any cells above the current processing cell receives a negative y-

ฉ 1995 A.C.T. GIS, Inc.

Page 62

-------
GRID Training Course

September 16. 1995

GRID Spatial Processing Concepts

offset (0,-); below a positive y-offset (0,+); to the right a positive
x-offset (+,0); and to the left a negative x-offset (-,0).

-2,-2

-1,-2

0,-2

1,-2

2,-2

-2,-1

-1,-1

0,-1

1,-1

2,-1

-2,0

-1,0

0,0

1,0

2,0

-2,1

-1,1

0,1

1,1

2,1

-2,2

-1,2

0,2

1,2

2,2

Note: Cell sizes are actually square in a grid!

Zonal Calculations

•	Cells are processed zone-by-zone based on the shape of a zone.

Calculating Distance and Direction

•	Distance is calculated from the center of a cell to the center of an
adjacent cell (which is the cell size times 1.412). To calculate the
distance between cells not in the immediate neighborhood, the
Euclidean distance is measured (using Euclidean functions).

•	Direction is calculated from center to center of disconnected
cells from any resultant direction grid.

Weight-distance Calculations

•	Cost-path calculations utilize weighted-surface grids (cost
surface or impedance grids). A weighted-surface assigns a value
to each cell that identifies the cost in some cost-measurement
system, to pass through the cell. It is assumed to starting point
and destination is the center of each cell.

Calculating Area

•	Area calculations are the result of multiplying the area of each
cell (derived by the cell size) and the number of cells in a zone.
The REGIONGROUP must first be used to calculate the area of
regions.

ฉ 1995 A.C.T. GIS, Inc.

Page 63

-------
GRID Training Course

September 16. 1995

GRID Spatial Processing Concepts

Surface Calculations

•	All surface functions are performed on the lattice view of a grid.
Surface calculations are many times interpolations of values
assigned to the center cells and the influence of surrounding
cells.

•	Aspect and slope are calculated from a cell's relationship to its
immediate neighbors.

ฉ 1995 A.C.T. GIS, Inc.

Page 64

-------
GRID Training Course

September 16. 1995

Map Algebra

Map Algebra

•	Map algebra is used to create new grids.

•	AML first processes the input on a Grid: command line.
Functions are evaluated and variable substitution performed.
The result is passed to the GRID interpreter. All communication
with the GRID interpreter is done using the map-algebra
language.

•	The building blocks for the map-algebra language are objects,
actions, and qualifiers.

•	Objects may be grids, tables, scalars, constants, and numbers,
they either store information or are values.

•	Commands, operators, and functions perform an action on input
objects.

•	Qualifiers and parameters control how and where an action is to
take place.

•	GRID commands are instructions for managing grids and the
environment in which they are analyzed.

•	GRID operators perform mathematical computations within and
between grids, tables, scalars, and numbers, and between valid
combinations of them.

•	The set of GRID operators is made up of arithmetic, relational,
accumulative, Boolean, bitwise, logical, and assignment
operators that support both integer and floating point values;
and combinatorial operators which simultaneously overlay
grids and maintain the input attributes.

•	GRID functions are spatial cartographic modeling tools
designed to analyze and operate on cell-based data.

ฉ 1995 A.C.T. GIS, Inc.

Page 65

-------
GRID Training Course

September 16. 1995

Map Algebra (Continued)

•	Scalars, constants, and numbers are single-value objects, usually
numeric, that can be used in conjunction with an operator or
function to achieve a desired result.

•	There are three main input types available with the GRID map
algebra. These are:

1.	expressions

2.	commands

3.	conditional and individual cell processing

Map Algebra Expressions

•	An expression can perform a single task on a grid, number, or
scalar.

•	A scalar is GRID variable. The Grid: PRINT 
command may be used to list the value of a scalar.

•	Most expressions are constructed with the "=" operator. For
example: Grid: outgrid = gridl + grid2

•	Operators can be placed in front of or between a grid, scalar, or
number, as in the example above.

•	Each operator has an assigned precedence value. Parentheses
overrule precedences. The GRID interpreter completes all
operations within parentheses first.

•	Parentheses can be nested, with the inner-most pair being
evaluated first.

•	The following table lists each operator by category, gives a
description of the operator, and lists its precedence:

ฉ 1995 A.C.T. GIS, Inc.

Page 66

-------
GRID Training Course			September 1g, 199$

Map Algebra (Continued)



Operators



Operator

Description of Operator

Precedence

Arithmetic:





-

unary minus

12

MOD

modulus

11

4-

multiplication

11

/

division

11

div

floating point division

11

+

addition

10

-

subtraction

10

Boolean:





A, not

complement of expression

12

&, and

and

3

!, or

or

2

I, xor

exclusive or

2

Relational:





<, It

less than

6

<=, le

less than or equal to

6

>, Rt

greater than

6

>=' Re

greater than or equal to

6

==, eq

equal to

6

A=, ne

not equal to

6

Bitwise:





AA

bitwise complement of expression

12

ป

right shift

7

ซ

left shift

7

&&

bitwise and

5

|i

bitwise or

4

I I

bitwise exclusive or

4

Combinatorial:





cand

and

9

cor

or

8

cxor

exclusive or

8

Logical:





diff

logical difference

8

in

contained in

8

over

over

8

Accumulative:





+=

adds and assigns value to

1

-+

subtracts and assigns value to

1



multiplies and assigns value to

1

/+

divides and assigns value to

1

(=

identifies minimum and assigns value to

1

}=

identifies maximum and assigns value to

1

Assignment:





=

create a new grid

1

:=

assign value to a temporary variable

1

ฉ 1995 A.C.T. GIS, Inc.

Page 67

-------
GRID Training Course			September 16, 1995

Map Algebra (Continued)

•	Expressions executing functions are dependent upon the syntax
and parameters associated with each function.

•	Functions have the same precedence and are simply executed
from left to right.

•	Functions can be nested. The inner-most function is executed
first, and its output is used as input for the surrounding
function. For example:

Grid: tempxx8 = con(isnull(tempxx7),0,taipxx7)
The ISNULLO function is executed first, followed by CON().

GRID Commands

•	GRID commands are similar to simple expressions, but they do
not use an assignment operator.

•	GRID commands complete a single task or sets a parameter that
will be used in future processing (i.e. SETCELL,
CREATEREMAP, etc.).

Map-algebra Input Types

•	Valid input types are grids, tables, scalars, constants, and
numbers.

•	All grids, tables, and scalars used on the right side of an
assignment must exist prior to processing the expression.

Map-algebra Results

•	All functions and operators either return a grid, table, or scalar.

•	A VAT will usually be created for a resulting integer grid. The
VAT will contain the items VALUE and COUNT.

•	Combinatorial operators used on two grids creates a new
composite grid.

ฉ 1995 A.C.T. GIS, Inc.

Page 68

-------
GRID Training Course			September 16, 1995

Map Algebra (Continued)

Multiple Outputs

•	Most functions generate a single new grid, table, or scalar, but
some create multiple grids. Examples are the Euclidean
allocation and cost allocation functions.

NOD ATA in GRID

•	NODATA is fully supported by GRID. A cell is assigned
NOD ATA when there is inadequate information about the cell
location for a theme.

•	The three ways NODATA can be treated in a computation are:

1.	Return NODATA for the location no matter what

2.	Ignore the NODATA and compute with available values

3.	Estimate what the value can be

•	The behavior of NODATA is discussed in ArcDOC for each
GRID function and operator.

•	For any operator or local function, if any cell in any of the input
grids are assigned NODATA, the output of the cell location will
be NODATA. This cannot be overridden.

•	For focal functions, if any cell location in a neighborhood of a
processing cell is assigned NODATA, the function will ignore
the NODATA value and compute with the remaining values.
The NODATA keyword can be used to force the processing cell
to be assigned NODATA if any cell in the neighborhood has a
value of NODATA.

•	For zonal functions, if any cell location on the input value grid
in a zone defined by the input zone grid is assigned NODATA,
the default is the function will ignore the NODATA value and
compute with the remaining values.

ฉ1995 A.C.T. GIS, Inc.

Page 69

-------
GRID Training Course

September 16. 1995

Map Algebra (Continued)

•	For Euclidean global functions, the NOD ATA value is ignored
for computations since the distance and direction are true
Euclidean distance and direction.

•	For cost global functions, any cell assigned NODATA in the per-
cell cost grid will be considered a barrier in computations, and
the cell locations containing NODATA values on the input
weight grid will contain NODATA on the output.

•	For the remaining global functions, when NODATA exists at
any location on the input grid, the output value for that location
will receive NODATA.

•	With the SELECT function, when the results of the evaluation of
the conditions are not true in the expression, NODATA is
returned rather than 0.

•	The TEST function returns 0 when the expression is false and 1
when the expression is true.

Direct Display of Analysis Results

•	It may sometimes be desirable to display the results of a map-
algebra expression rather than creating an output grid (such as
experimenting with new functionality). This can be
accomplished by using the $$display symbolic name for the
output argument in a map-algebra expression. For example:

Grid: $$display = float(gridl6)

ฉ 1995 A.C.T. GIS, Inc.

Page 70

-------
GRID Training Course

GRID Functions

September 16. 1995

Miscellaneous Functions

•	The following functions provide functionality necessary for
GRID operations, but not necessarily pertinent to any single
GRID application:

The ABS Function

•	Calculates the absolute value of the input.

•	ABS ()

•	Input values can be integer or floating point. If the input values
are integer, the output values will be integer. And if the input
values are floating point, the output values will be floating
point.

•	Input values can be negative or positive.

•	The absolute value may be calculated on an input grid, scalar, or
number.

ฉ1995 A.C.T. GIS, Inc.

Page 71

-------
GRID Training Course

GRID Functions

September 16. 1995

The CEIL Function

•	Returns the next highest whole value that is greater than or
equal to the input values.

•	CEIL ()

•	Input values can be negative or positive.

•	If the input value has values to the right of the decimal, the
output will be assigned the next highest whole value. For
example:

Input Output
1.1	2.0

1.0	1.0

-0.5	0.0

ฉ 1995 A.C.T. GIS, Inc.

Page 72

-------
GRID Training Course

GRID Functions

September 16. 1995

The CON Function

•	Performs one or more conditional if/else evaluations.

•	CON(, /

{, }, ...

{ , }, {false_expression})

•	 is any valid Boolean or relational expression
involving multiple grids, scalars, numbers, or expressions.

•	 is true.

•	Multiple ,  statements may be
specified.

•	{false_expression} is the value to be assigned if none of the
 statement are true.

•	If the any  arguments or the
{false_expressionj argument contains floating point values, the
output grid will be floating point.

•	The CON functions allows the use of any grid function and the
embedding of functions.

•	If the  evaluates to a non-zero number, the condition
is considered true.

•	If no {false_expression} is supplied, NODATA is assigned to
those cells where all  arguments evaluated false.

•	In the example statement below:

Grid: tempxx8 = con(isnull(tempxx7),0,tempxx7)

If the input cell value in tempxx7 is NODATA, the ISNULL
function assigns a value of 1. Since 1 is non-zero, the condition
is considered true and CON assigns 0 to the cell. Otherwise, the
original cell value is used as the output cell value. In this

ฉ 1995 A.C.T. GIS, Inc.

Page 73

-------
GRID Training Course

September 16.1995

GRID Functions

The CON Function (Continued)

manner, NOD ATA cell values can be converted to 0 (which is
required when a function will not operate as desired on
NOD ATA cell values.

• In the next example:

Grid: tempxx8 = con(tempxx7 == 0, 99,tempxx7)

If the input cell value in tempxx7 is 99 (using the == relational
operator), the CON function assigns a value of 0. Otherwise, the
original cell value is used as the output cell value.

ฉ 1995 A.C.T. GIS, Inc.

Page 74

-------
GRID Training Course	September 16. 1995

GRID Functions

The FLOAT Function

•	Converts integer values to floating point values.

•	FLOAT ()

•	Input values can be negative or positive.

•	If floating point values are input, the output will be the same as
the input.

•	An integer value of 1 would be converted to 1.0.

ฉ 1995 A.C.T. GIS, Inc.

Page 75

-------
GRID Training Course

GRID Functions

September 16. 1995

The FLOOR Function

•	Returns the greatest integer value that is smaller than or equal to
the input values.

•	FLOOR ()

•	Input values can be negative or positive.

If the input value has values to the right of the decimal, the output
will be assigned the next lowest whole value.

•	For example, an input of 1.0 returns 1.0, an input of 1.1 returns
1.0, and an input of -0.2 returns -1.0.

ฉ 1995 A.C.T. GIS, Inc.

Page 76

-------
GRID Training Course

GRID Functions

September 16. 1995

The FMOD Function

•	Divides the values of the first input by the second input and
returns the remainder on a cell-by-cell basis.

•	FMOD (, )

•	The output values are always floating point regardless of the
input values.

•	A value divided by 0 is assigned NOD ATA.

ฉ 1995 A.C.T. GIS, Inc.

Page 77

-------
GRID Training Course	September 16.1995

GRID Functions

The INT Function

•	Converts input floating point values to integer values through
truncation.

•	INT ()

•	Input values should be floating point and can be either positive
or negative.

•	If rounding is preferred rather than truncating, add 0.5 to the
expression (outgrid = int(ingrid + 0.5)

ฉ1995 A.C.T. GIS, Inc.

Page 78

-------
GRID Training Course

GRID Functions

September 16. 1995

The ISNULL Function

•	Returns "1" if input value is NOD ATA, and "0" if it is not.

•	ISNULL ()

•	Input values can be positive or negative.

•	The output value types are always integer. The values are either
0 or 1.

•	In the example statement below:

Grid: tempxx8 = con(isnull(tempxx7),0,tempxx7)

If the input cell value in tempxx7 is NOD ATA, the ISNULL
function assigns a value of 1. Since 1 is non-zero, the condition
is considered true and CON assigns 0 to the cell. Otherwise, the
original cell value is used as the output cell value. In this

ฉ 1995 A.C.T. GIS, Inc.

Page 79

-------
GRID Training Course	 September 16. 1995

GRID Functions

The MERGE Function

•	Merges multiple, possibly non-adjacent input grids into a single
grid based on order of input.

•	MERGE (...)

•	If any input grid is floating point, the output will be floating
point.

•	If the input grids do not have the same extent, the output grid
will be assigned a boundary as the minimum bounding
rectangle of all inputs.

•	A maximum of 50 grids may be opened at one time. This allows
49 inputs to be specified and 1 output grid.

•	If floating point grids have difference cell sizes, RESAMPLEO
may be used to resample the data using BILINEAR interpolation
or CUBIC convolution. Otherwise, MERGE uses the NEAREST
neighbor method for resampling the cell sizes and determining
output cell values.

•	Input grids may be adjacent, entirely overlapping, partially
overlapping, or entirely separated.

•	Output cell values are assigned based on the first value at each
cell location that is not NODATA, based on the order the grid
arguments are specified.

ฉ 1995 A.C.T. GIS, Inc.

Page 80

-------
GRID Training Course

GRID Functions

September 16. 1995

The MOSAIC Function

•	Merges multiple adjacent continuous grids and performs
interpolation in the overlapping areas.

•	MOSAIC (...)

•	MOSAIC is designed primarily for continuous data. It can
minimize the abrupt changes along the boundaries of
overlapping grids. Examples are satellite images, DEMs, etc.

•	The output grid will be a floating point grid unless all inputs
are integer.

•	A maximum of 50 grids may be opened at one time. This allows
49 inputs to be specified and 1 output grid.

•	If floating point grids have difference cell sizes, RESAMPLEO
may be used to resample the data using BILINEAR interpolation
or CUBIC convolution. Otherwise, MERGE uses the NEAREST
neighbor method for resampling the cell sizes and determining
output cell values.

•	The order the grids are listed as arguments has not impact on
the output cell values assigned. Output cell values are
determined by a weighted average method for overlap areas.

ฉ 1995 A.C.T. GIS, Inc.

Page 81

-------
GRID Training Course			September 16, 1995

GRID Functions

The NORMAL Function

•	Creates a grid with randomly dispersed values of a normal
distribution.

•	NORMAL ()

•	There are no arguments for the NORMAL function. The output
is a grid of the same extent and cell size as the current analysis
window. SETWINDOW and SETCELL must be specified before
using NORMAL.

•	The output grid is always floating point.

•	By default, the NORMAL function sets a mean to 0 and a
standard deviation to 1. These can be changed by the user. For a
mean of 50 and s standard deviation of 3.2, the expression would
be:

Grid: outgrid = normal() * 3.2 + 50

ฉ1995 A.C.T. GIS, Inc.

Page 82

-------
GRID Training Course

GRID Functions

September 16. 1995

The PICK Function

•	Using the values of an input grid, determines which expression
will be used to compute output values.

•	PICK (, ,...,)

•	 is an input integer or floating point grid, or an
expression resulting in a grid.

•	,..., is any valid map-algebra
expression or a single grid, number, or scalar. If the value in
 equals 1, then the first expression in the expression list is
used to compute the output cell value. If the value in the input
grid equals 2, the second expression will be used, and so on.

•	Any NOD ATA value on the input grid will receive NOD ATA
on the output grid.

•	If there is not an expression corresponding to the cell value, the
cell is assigned NOD ATA.

ฉ 1995 A.C.T. GIS, Inc.

Page 83

-------
GRID Training Course	September 16.1995

GRID Functions

The RAND Function

•	Generates a random number between "0" and "1".

•	RANDO

•	There are no arguments with the RAND function. The output is
a grid of the same size as the current analysis window, or a
scalar. SETWINDOW and SETCELL must be set before using
RANDO.

•	The output values are always floating point.

•	A linear stretch is needed to display values less that 1.0.

ฉ 1995 A.C.T. GIS, Inc.

Page 84

-------
GRID Training Course

GRID Functions

September 16.1995

The SAMPLE Function

•	Lists the values of a group of cells from one or more grids.

•	SAMPLE (, {grid...grid})

•	SAMPLE (* I point_file>, {grid—grid},

{NEAREST I BILINEAR I CUBIC})

•	 defines the cells to sample. Cells in mask grid
with value values will be sampled.

•	{grid...grid} is the name of one or more grids whose values will
be sampled based upon 

•	<*> allows interactive specification of input points.

•	 is an ASCII text file containing coordinate points to
be sampled.

•	{NEAREST I BILINEAR I CUBIC} specifies the resampling
algorithm to use when sampling a grid. It is used only when
point coordinates are entered as input.

•	If the cell in the sample {grid...grid} is NOD AT A, its values will
be listed in the output file as missing.

ฉ1995 A.C.T. GIS, Inc.

Page 85

-------
GRID Training Course 	September 16. 1995

GRID Functions

The SAMPLE Function (Continued)

•	If no grid is specified, the output will be zone#, x and y
coordinates of the cells in  or points specified by
<*> or in .

•	An output will be created (outfile = sample (arguments)).

ฉ 1995 A. C.T. GIS, Inc.

Page 86

-------
GRID Training Course

September 16. 1995

GRID Functions

The SETNULL Function

•	returns NOD ATA if the evaluation of the input condition is
true; if it is false, returns the value specified by the second input
argument.

•	SETNULL (, {grid I scalar I number})

•	 can be a relational expression or a single grid,
scalar, or number, or expression resulting in a single grid, scalar,
or number.

•	{grid I scalar I number} determines what the output value will
be if the evaluation condition is false.

•	Input values can be positive or negative.

•	If the input value is a single value greater than 0, the output will
be NODATA at all cell locations (output = setnull(3, ingridl))

•	SETNULL is useful for changing values that meet a certain
condition to NODATA. This can be used to remove certain cells
from further processing.

ฉ 1995 A.C.T. GIS, Inc.

Page 87

-------
GRID Training Course

September 16. 1995

GRID Functions

Individual Cell Processing

•	The DOCELL block and neighborhood notation are two
facilities within the GRID map-algebra language that allow the
development of custom functions and the creation of application
models.

The DOCELL Block

•	The DOCELL block provides the capability to control
processing on a cell-by-cell basis with conditional statements,
built-in procedures, and access to variables associated with a
grid.

•	A block begins with the word DOCELL and ends with the word
END.

•	A DOCELL block is comparable to a GRID function. However,
it can as many statements and expressions as desired.

•	A DOCELL block can accept multiple grids, scalars, and
combination of grids and scalars. Integer and floating point
values are acceptable.

•	A DOCELL block may be executed from an AML file (executed
with the &RUN directive) or from the Grid: prompt.

•	Temporary grids may be created in a DOCELL block using the
temporary assignment operator

•	The use of neighborhood notation is supported within a
DOCELL block.

•	The IF and WHILE statements may be used within a DOCELL
block.

ฉ 1995 A.C.T. GIS, Inc.

Page 88

-------
GRID Training Course

GRID Functions

September 16. 1995

The IF Statement

•	Performs a conditional if/else evaluation on a cell-by-cell basis
within the analysis window.

•	IF ()  {ENDIF}

•	IF () 

{ELSE IF  } {ELSE }
{ENDIF}

•	 is any valid Boolean or relational expression
involving multiple grids, scalars, or numbers.

•	 is the statement of expression that will be used
to compute the output value if  evaluates true.

•	{ENDIF} is an optional keyword used to signal the end of input
for an IF statement. An IF statement will not be processed until
an ENDIF or a statement outside the scope of the IF is executed.

•	ELSE IF allows for an else clause. IF the IF condition is false,
the ELSE IF clause is evaluated.

ฎ ELSE  is the statement list evaluated when a
prior condition evaluates false.

•	Example:

Grid: if (ingrid > 5) outgrid = 100
:: else outgrid = 0
:: endif

•	If no ELSE is specified, NOD ATA is assigned to cells evaluating
to false for 

•	If multiple statements are included in , the
block must begin with the keyword BEGIN or the character "{".
The block must end with the keyword END or the character
For example:

ฉ 1995 A.C.T. GIS, Inc.

Page 89

-------
GRID Training Course	September 16. 1995

GRID Functions

The IF Statement (Continued)

outval = scalar(O)

DOCELL
if (ingrid > 5)
begin
outval = outval + 1
outgrid = 100 * outval
end

END

ฉ 1995 A.C.T. GIS, Inc.

Page 90

-------
GRID Training Course

September 16.1995

GRID Functions

The WHILE Statement

•	Repeats a statement list body as long as the tested condition is a
semi-Boolean true value (non-zero) on a cell-by-cell basis in the
analysis window.

•	WHILE () 

•	 is any valid Boolean or relational expression
involving single or multiple grids, scalars, or numbers.

•	 is one or more assignment expressions of other
valid statement used to compute the output value as long as
 is true.

•	If multiple statements are included in , the
block must begin with the keyword BEGIN or the character
The block must end with the keyword END or the character
For example:

DOCELL
var:= 10

outgrid = ingridl
while (var > 0)
begin

outgrid = ingrid + outgrid
var := var -1
end
END

ฉ 1995 A.C.T. GIS, Inc.

Page 91

-------
GRID Training Course

GRID Functions

September 16. 1995

The SCALAR Function

•	Returns the result of a map algebra expression involving
numbers as a numeric value that can be assigned to a scalar
variable.

•	SCALAR ()

•	The output type is the type of the input value.

•	A permanent scalar variable is created. The REMOVESCALAR
command can be used to remove a scalar variable.

•	If SCALAR is used outside a DOCELL block, the variable will
be set as a global, and is accessible from within a DOCELL
block.

•	If SCALAR is used within a DOCELL block, the variable can be
accessed with the AML show function [SHOW
].

•	Numbers, both integer and floating point, are the only valid
inputs.

ฉ1995 A.C.T. GIS, Inc.

Page 92

-------
GRID Training Course

GRID Functions

September 16. 1995

The := Operator

•	Creates a temporary output grid from an input grid, scalar,
number, or expression on a cell-by-cell basis within a DOCELL
block.

•	 := 

•	 is the temporary output grid.

•	 is the object operated on.

•	:= can only be used in a DOCELL block.

•	The size of the output grid is the size of the analysis window.

•	The assignment operators and	produce the same
results. However, := does not write the results to disk but saves
them in memory.

•	The SCALAR function can be used to force the output to be a
scalar and not a grid (out := scalar(5+3))

ฉ 1995 A.C.T. GIS, Inc.

Page 93

-------
GRID Training Course

GRID Functions

September 16. 1995

Trigonometric Functions

• The following table indicates the trigonometric functions within
GRID, a description of their use, and their usage:

Function

Description

Usage

ACOS

Calculates the inverse cosine of the
input

ACOS()

ACOSH

Calculates the inverse hyperbolic
cosine of the input

ACOSH()

ASIN

Calculates the inverse sine of the
input

ASIN()

ASINH

Calculates the inverse hyperbolic sine
of the input

ASINH()

ATAN

Calculates the inverse tangent of the
input

ATAN()

ATAN2

Calculates the inverse tangent (based
on y/x) of the input

ATAN2(,
ATAN2()

ATANH

Calculates the inverse hyperbolic
tangent of the input

ATANH()

COS

Calculates the cosine of the input

COS()

COSH

Calculates the hyperbolic cosine of the
input

COSH()

SIN

Calculates the sine of the input

SIN()

SINH

Calculates the hyperbolic sine of the
input

SINH()

TAN

Calculates the tangent of the input

TAN()

TANH

Calculates the hyperbolic tangent of
the input

TANH()

ฉ 1995 A.C.T. GIS, Inc.

Page 94

-------
GRID Training Course

GRID Functions

September 16. 1995

Logarithmic and Exponential Functions

• The following table indicates the logarithmic and exponential
functions within GRID, a description of their use, and their
usage:

Function

Description

Usage

EXP

Calculates the base e exponential of
the input

EXP()

EXP10

Calculates the base 10 exponential of
the input

EXP10()

EXP2

Calculates the base 2 exponential of
the input

EXP2()

LN

Calculates the natural logarithm of
the input

LN()

LOGIO

Calculates the base 10 logarithm of
the input

LOG10()

LOG2

Calculates the base 2 logarithm of the
input

LOG2()

POW

Calculates the nth power of the input

POW(, )

SQR

Calculates the square of the input

SQR()

SQRT

Calculates the square root of the input

SQRT()

ฉ 1995 A.C.T. GIS, Inc.

Page 95

-------
GRID Training Course

GRID Functions

September 16.1995

Statistical Functions

• The following table indicates the logarithmic and exponential
functions within GRID, a description of their use, and their
usage:

Function

Description

Usage

EQUALTO

Evaluates, on a cell-by-cell
basis, the number of times in
an argument list that the
input grid values are equal
to the value specified by the
first argument.

EQUALTO(,
)

GREATERTHAN

Evaluates, on a cell-by-cell
basis, the number of times in
an argument list that the
input grid values are greater
than the value specified by
the first argument.

GREATERTHAN(,
)

LESSTHAN

Evaluates, on a cell-by-cell
basis, the number of times in
an argument list that the
input grid values are less
than the value specified by
the first argument.

LESSTHAN(,
)

LPOS

Determines, on a cell-by-cell
basis, the position of the
input grid with the
minimum value in the
argument list.

LPOS()

MAJORITY

Uses multiple input grids to
determine the majority value
(the value that appears most
often) on a cell by cell basis.

MAJORITY()

MAX

Uses multiple input grids to
determine the maximum
value on a cell-by-cell basis.

MAX()

MEAN

Uses multiple input grids to
determine the mean value
on a cell-by-cell basis.

MEAN()

MED

Uses multiple input grids to
determine the median value
on a cell-by-cell basis.

MED()

MIN

Uses multiple input grids to
determine the minimum
value on a cell-by-cell basis.

MIN()

MINORITY

Uses multiple input grids to
determine the minority
value on a cell-by-cell basis.

MINORITY()

ฉ 1995 A.C.T. GIS, Inc.

Page 96

-------
GRID Training Course	September 16, 1995

GRID Functions

Statistical Functions (Continued)

Function

Description

Usage

MLCLASSIFY

Performs maximum
likelihood classification on a
stack and creates the
classification grid.

MLCLASSIFY(, ,
(reject_fraction). (EQUAL I SAMPLES
I FILEj, (o_priori_file|, {o_reject_grid})

POPULARITY

Determines the value in an
argument list that is at a
certain level of popularity on
a cell-by-cell basis.

POPULARITY(,
)

RANK

Returns the value in the nth
rank order of the argument
list.

RANK(,
)

UPOS

Determines, on a cell-by-cell
basis, the position of the
input grid with the
minimum value in the
argument list.

UPOS()

VARIETY

Uses multiple input grids to
determine the variety of
values on a cell-by-cell basis.

VARIETY()

ฉ 1995 A.C.T. GIS, Inc.

Page 97

-------
GRID Training Course

GRID Functions

September 16. 1995

Selection Functions

•	The following section presents some descriptions of selection
functions:

The SELECT Function

•	Based on the evaluation of the , selects cell
values from the input grid on a cell-by-cell basis within the
analysis window.

•	SELECT(/ , {o_value_item})

•	 is the input grid the selection is performed upon.

•	 is a logical INFO selection which operates
on VALUE and other attributes of a 's VAT. Those cells
which evaluate true are selected and written to the output grid.
Those cells that are not selected are set to NOD ATA.

•	If the input grid is floating point, VALUE is used for the
selection, and the output grid will be floating point.

•	{o_value_item} is an alternate item in a VAT (used only if 
is integer) used as the VALUE in the output grid. If no
{o_value_item} is given, the input grid VALUE is written to the
output grid.

•	The general form of a logical expression is:

  

•	The logical expression must be contained within single quotes.
For example:

Grid: outgrid = select(ingrid, 'value > 100')

ฉ 1995 A.C.T. GIS, Inc.

Page 98

-------
GRID Training Course	September 16.1995

GRID Functions

The SELECT Function (Continued)

•	If the logical expression contains a character string, it must be
doubled quoted. For example:

Grid: outgrid = select(ingrid, 'name cn ''test'")

•	Valid logical expression operators are:

EQ

=

NE

<>

GE

>=

LE

<=

LT

<

GT

>

CN



NC



IN



LK



• Valid logical expression connectors are: AND, OR and XOR.

ฉ 1995 A.C.T. GIS, Inc.

Page 99

-------
GRID Training Course

GRID Functions

September 16.1995

The SELECTBOX Function

•	Selects cells from the input grid that are either inside or outside
a specified box within the analysis window.

•	SELECTBOX(, ,

{INSIDE I OUTSIDE})

•	SELECTBOX(, <*>, {INSIDE I OUTSIDE})

•	 is the input grid the selection is performed upon.

•	 allows the box to be specified in map
units.

•	{INSIDE} indicates the cells inside the box will be selected. All
cells outside will receive NOD AT A.

•	{OUTSIDE} indicates the cells outside the box will be selected.
All cells inside will receive NODATA.

•	<*> means the box is defined interactively.

•	An alternate item in the VAT can be specified using the syntax
.. For example:

output = selectbox(ingrid.item, *)

•	The center of a cell is used to determine whether a cell is inside
or outside the box.

•	When the  is used, the grid does not
have to be displayed on the screen.

•	When <*> is used, the grid should be displayed on the screen.

ฉ 1995 A.C.T. GIS, Inc.

Page 100

-------
GRID Training Course

GRID Functions

September 16.1995

The SELECTCIRCLE Function

•	Selects cells from the input grid that are either inside or outside
a specified circle within the analysis window.

•	SELECTCIRCLE(, , {INSIDE I OUTSIDE})

•	SELECTCIRCLE(, <*, r>, {INSIDE I OUTSIDE})

•	SELECTCIRCLE(/ <*>, {INSIDE I OUTSIDE})

•	 is the input grid the selection is performed upon.

•	 allows the center of the circle and the radius to be
specified in map units.

•	<*, r> allows the center of the circle to be specified interactively
and the radius given explicitly.

•	<*> allows the center of the circle and the radius to be specified
interactively.

•	{INSIDE} indicates the cells inside the circle will be selected.
All cells outside will receive NODATA.

•	{OUTSIDE} indicates the cells outside the circle will be selected.
All cells inside will receive NODATA.

•	An alternate item in the VAT can be specified using the syntax
.. For example:

output = selectcircle(ingrid.item, *)

•	The center of a cell is used to determine whether a cell is inside
or outside the box.

•	When <*> is used, the grid should be displayed on the screen.

ฉ 1995 A.C.T. GIS, Inc.

Page 101

-------
GRID Training Course	September 16.1995

GRID Functions

The TEST Function

•	Uses a Boolean evaluation of the  to test the
cell values from the input grid and to set the output to "1" or "0"
on a cell-by-cell basis within the analysis window.

•	TEST(, )

•	 is the input grid the test is performed upon.

•	 is a logical INFO selection which operates
on VALUE and other attributes of a /s VAT. Those cells
which evaluate true are assigned 1 in the output grid. Those
cells that are not selected are set to 0.

•	If the input grid is floating point, VALUE is used for the
selection, and the output grid will be floating point.

•	The general form of a logical expression is:

  

•	The logical expression must be contained within single quotes.
For example:

Grid: outgrid = test(ingrid, 'value > 100')

•	If the logical expression contains a character string, it must be
doubled quoted. For example:

Grid: outgrid = test(ingrid, 'name cn "test"')

•	Valid logical expression operators are:

EQ

=

NE

<>

GE

>=

LE

<=

LT

<

GT

>

CN



NC



IN



LK



ฉ 1995 A.C.T. GIS, Inc.

Page 105

-------
GRID Training Course

GRID Functions

September 16.1995

Reclassification Functions

•	The following section presents some descriptions of
reclassification functions:

The RECLASS Function

•	Reclassifies (or changes) the value of input cells using a remap
table on a cell-by-cell basis within the analysis window.

•	RECLASS(/ / {DATA I NODATA},

{in_item}, {out_item})

•	 is the input grid to reclassify.

•	 is an INFO or ASCII remap table.

•	{DATA} indicates that if the input value is not present in the
, the value should remain intact for that location
on the output grid.

•	{NODATA} indicates that if the input value is not present in the
, the value should be assigned NOD ATA for that
location on the output grid.

•	{in_item} specifies the item in an INFO remap table that is to be
used to correlate the values on the input grid that will be
reclassed.

•	{out_item} is the item in an INFO remap table that is to be used
to change or reclass the input values to the values contained in
{out_item}.

•	The output grid will always be integer type. If the output
values in the remap table are floating point, they are truncated
before the reclass.

•	Any value in the VAT can be used for the reclass. For example:

Grid: outgrid = reclass(ingrid.ph, ph.rmt)

ฉ 1995 A.C.T. GIS, Inc.

Page 106

-------
GRID Training Course

GRID Functions

September 16. 1995

The RECLASS Function (Continued)

•	If a mask is set, the cell locations masked out will be assigned
NODATA.

•	The input grid must have a valid .STA file created with the
GRID BUILDSTA command.

•	RECLASS assigns input values not explicitly listed in the remap
table as either NODATA or an output value identical to the
input value, depending on the option specified.

•	Ranges can be specified in an ASCII remap table only. INFO
remap tables are explicit, with ranges not be interpolated as
with display remap tables.

ฉ 1995 A.C.T. GIS, Inc.

Page 107

-------
GRID Training Course

GRID Functions

September 16.1995

The SLICE Function

•	Slices (or changes) a range of values of the input cells by
specified ranges, zones of equal area, or zones with equal
intervals within the analysis window.

•	SLICE(/ TABLE, , {in_item}, {out_item},

{in_min})

•	SLICE(, EQAREA, {nzones}, {base_zone#}, {in_min},

{in_max}

•	SLICE(, EQINTERVAL, {nzones}, {base_zone#}, {in_min},

{in_min})

•	 is the input grid to be sliced.

•	TABLE indicates a remap table will be used in the slicing
process.

•	 is an ASCII or INFO remap table specifying
which values are to be changed and to what output values.

•	{in_item} is the input item in an INFO remap table.

•	{out_item} is the output item in an INFO remap table.

•	{in_min} is a number that identifies the minimum value from
the input grid for slicing.

•	EQAREA indicates that the input values will be divided into the
number of zones specified by {nzones} with each zone having a
similar number of cells (each zone represents a similar amount
of area).

•	{nzones} defines the number of zones that will be used with the
calculation of equal area. The output grid will have (nzones}
with similar numbers of cells.

•	{base_zone#} is an integer that defines the lowest zone value on
the output grid.

ฉ 1995 A.C.T. GIS, Inc.

Page 108

-------
GRID Training Course

September 16. 1995

GRID Functions

The SLICE Function (Continued)

•	{in_min} is a number that identifies cells with values below
{in_min} should be assigned NODATA.

•	{in_max} is a number that identifies cells greater than {in_max}
should be assigned NODATA.

•	EQINTERVAL indicates the slice is determined by the range of
the input values and then divides the ranges into {nzones}. Each
zone on a sliced output grid has the potential of having input
cell values that have the same range from the extremes.

•	{nzones} defines the number of zones that will be used with the
calculation of equal area. The output grid will have (nzones}
each containing equal value ranges on the output grid.

•	{base_zone#} is an integer that defines the lowest zone value on
the output grid.

•	{in_min} is a number that identifies cells with values below
{in_min} should be assigned NODATA.

•	{in_max} is a number that identifies cells greater than {in_max}
should be assigned NODATA.

•	INFO remap tables can have more than two items (as in display
remap tables) and these items can be used as input and output
remap items.

•	The result of using an ASCII remap table is the same for SLICE
as it is for display.

•	Any value in the VAT can be used for the slice example:

Grid: outgrid = slice(ingrid.ph, ph.rmt)

•	If a mask is set, the cell locations masked out will be assigned
NODATA.

ฉ 1995 A.C.T. GIS, Inc.

Page 109

-------
GRID Training Course

GRID Functions

Sfintember 16.1995

Shape Analysis Functions

•	The following section presents some descriptions of shape
analysis functions:

The EXPAND Function

•	Expands the selected zones by a specified number of cells.

•	EXPAND(, , LIST, )

•	EXPAND(, , FILE, )

•	EXPAND(, , TABLE, , {item})

•	 is the input grid to expand.

•	 are the number of cells to expand each selected zone.

•	LIST indicates the zones to be selected will be listed on the
command line as .

•	 is the list of zones to be selected up to a maximum
of 20 values.

•	FILE indicates the list of zones to be selected will be listed in an
ASCII text file. An explicit zone should be listed on a single
line, and ranges should be listed be listed together, space
delimited on the same line.

•	 is an ASCII text file containing the zones to select.
An explicit zone should be listed on a single line, and ranges
should be listed be listed together, space delimited on the same
line. The file must be sorted in ascending order.

•	TABLE indicates the zones to be selected are listed as single
values in an INFO table.

•	 is the INFO table containing the values to select.
The table should contain the item VALUE or an optional item
specified as {item}.

ฉ 1995 A.C.T. GIS, Inc.

Page 110

-------
GRID Training Course

SfiPtember 16.1995

GRID Functions

The EXPAND Function (Continued)

•	The expansion occurs in all directions.

•	When two foreground zones expand into the same background
zone, the conflict is resolved based on the value of the majority
of surrounding cells.

•	NOD ATA cells are always considered as background cells, and
neighboring cells can expand into NODATA cells. NODATA
cells will never expand into their neighbors.

ฉ 1995 A.C.T. GIS, Inc.

Page 111

-------
fiRID Training Course	September 16.1995

GRID Functions

The REGIONGROUP Function

•	Records for each cell in the output the identity of the connected
region to which it belongs within the analysis window. A
unique number is assigned to each region.

•	REGIONGROUP(/ {o_remap_table}, {FOUR I EIGHT},

{WITHIN I CROSS}, {excluded_value},

{LINK I NOLINK})

•	Any two cells with the same value are considered a zone.

•	A region is each group of connected cells within a zone.

•	 is the input grid whose regions will be grouped.

•	{o_remap_table} is the name of the resulting remap table that
identifies the input value or values from the original grid that
were used to create the output zone.

•	{FOUR} defines connectivity as being the cells to the right, left,
top, and bottom of the cell being processed.

•	{EIGHT} defines connectivity as the eight neighborhood cells
surrounding the processing cell.

•	{WITHIN} will test for connectivity between input values that
are within the same zone. The only cells that can be grouped are
in the same zone.

•	{CROSS} will test for connectivity by the spatial requirements of
the FOUR and EIGHT keywords between cells with any values
except for cells with a value of {excluded_value}.
{excluded_value} must be specified.

•	{excluded_value} identifies a value such that if a cell location
contains the value, no connectivity will be evaluated no matter
which keyword is used.

ฉ 1995 A.C.T. GIS, Inc.

Page 112

-------
GRID Training Course	.	September 16. 1995

GRID Functions

The REGIONGROUP Function (Continued)

•	{LINK} means an item LINK will be added to the VAT of the
output grid to hold the original values for each newly created
cell.

•	{NOLINK} means the VAT will contain only the VALUE and
COUNT items.

•	The output grid will always be integer.

•	The input values to be regrouped using any VAT item using the
syntax ..

•	REGIONGROUP is useful when analysis must be completed on
regions, not zones.

•	Cell locations that are excluded values are assigned 0 so that
they are not confused with NOD ATA cells.

•	If a mask is set, those cells that have been masked out will be
assigned NODATA.

ฉ 1995 A.C.T. GIS, Inc.

Page 113

-------
GRID Training Course

GRID Functions

September 16. 1995

The SHRINK Function

•	Shrinks the selected zones by a specified number of cells.

•	SHRINK(, / LIST, )

•	SHRINK(, , FILE, )

•	SHRINK(, , TABLE, , {item})

•	 is the input grid to expand.

•	 are the number of cells to shrink each selected zone.

•	LIST indicates the zones to be selected will be listed on the
command line as .

•	 is the list of zones to be selected up to a maximum
of 20 values.

•	FILE indicates the list of zones to be selected will be listed in an
ASCII text file. An explicit zone should be listed on a single
line, and ranges should be listed be listed together, space
delimited on the same line.

•	 is an ASCII text file containing the zones to select.
An explicit zone should be listed on a single line, and ranges
should be listed be listed together, space delimited on the same
line. The file must be sorted in ascending order.

•	TABLE indicates the zones to be selected are listed as single
values in an INFO table.

•	 is the INFO table containing the values to select.
The table should contain the item VALUE or an optional item
specified as {item}.

ฉ 1995 A.C.T. GIS, Inc.

Page 114

-------
GRID Training Course	September 16. 1995

GRID Functions

The SHRINK Function (Continued)

•	The shrinkage occurs in all directions.

•	When two adjacent regions are part of the selected set to
SHRINK, there is no change in the boundary between them.

•	NODATA has the same priority as any value to invade areas
vacated by SHRINK. Therefore, if a selected value is adjacent to
NODATA, it may become NODATA following SHRINK.

ฉ 1995 A.C.T. GIS, Inc.

Page 115

-------
GRID Training Course

GRID Functions

September 16. 1995

Data Cleanup Functions

•	The following section presents some descriptions of data
cleanup functions:

The BOUNDARYCLEAN Function

•	Smoothes the boundary between zones by expanding and
shrinking the boundary.

•	BOUNDARYCLEAN(, {NOSORT I DESCEND I ASCEND},

{TWOWAY I ONEWAY})

•	 is the input integer grid.

•	{NOSORT} does no sorting by size. This is the default. Zones
with larger values have a higher priority to expand into zones
with smaller values.

•	{DESCEND} sorts zones in descending order by size.

•	{ASCEND} sorts zones in ascending order by size.

•	{TWOWAY} performs expansion and shrinking according to
sorting type, then does an additional shrinking and expansion
with the priority reversed. This is the default.

•	{ONEWAY} performs expansion and shrinking only once,
according to the sorting type.

•	All regions of less than 3 cells in the x or y direction will be
changed.

•	Expansion is identical in the first and second pass.

•	In the ONEWAY or first pass of the TWOWAY option,
NODATA cells have lowest priority. NODATA cells have the
highest priority in the second pass of the TWOWAY option.

ฉ 1995 A.C.T. GIS, Inc.

Page 116

-------
GRID Training Course	September 16.1995

GRID Functions

The BOUNDARYCLEAN Function (Continued)

•	The shrinking of the ONEWAY option and the first pass of the
TWOWAY option are different than the second pass of the
TWOWAY option. In the first pass, for any processing cell in
the expanded grid which has a neighbor of the original value of
the processing cell, the original value of the processing cell will
be recovered. In the second pass of the TWOWAY option, any
cell in the expanded grid which is not surrounded completely by
eight cells of the same value will recover its original value.

•	BOUNDARYCLEAN is primarily used for cleaning ragged
edges between zones. It uses an expand then shrink method
which cleans boundaries on a relatively large scale.

ฉ 1995 A.C.T. GIS, Inc.

Page 117

-------
GRID Training Course

GRID Functions

September 16. 1995

The MATORITYFILTER Function

•	Replaces cells in grid based on the majority of their contiguous
neighboring cells.

•	MAJORITYFILTER(, {FOUR I EIGHT),

{MAJORITY I HALF})

•	 is the input integer grid.

ฎ {FOUR} means the kernel of the will be the four direct
neighbors (left, right, top, bottom) to the process cell. This is the
default.

•	{EIGHT} means the kernel of the will be the eight nearest
neighbors (a 3x3 window) to the present cell.

•	{MAJORITY} means a majority of the cells must have the same
value and be orthogonally connected (left, right, top, bottom).
Three out of four or five of the eight must have the same value.
This is the default.

•	{HALF} means half the cells must have the same value and be
orthogonally connected. Two out of four or four out of eight
connected cells must have the same value. Half will have more
of a smoothing effect.

•	The MAJORITYFILTER has two criteria which must be satisfied
before replacement can occur. These are:

1.	The number of neighboring cells of a similar value must
be large enough, MAJORITY or HALF.

2.	Those cells must be contiguous about the center of the
filter kernel.

ฉ 1995 A.C.T GIS, Inc

Page 118

-------
GRID Training Course			September 16. 199$

GRID Functions

The NIBBLE Function

•	Replaces areas in a grid corresponding to a mask with the values
of the nearest neighbor.

•	NIBBLE(, , {ALL I DATAONLY})

•	 is the input integer grid.

•	 is the name of the integer grid to be used as the
mask. Cells with NODATA as their value will be nibbled.

•	{ALL} is a keyword that specifies that the nearest neighbor value
will be used whether it is NODATA or another data value in the
grid. NODATA values are free to nibble into areas defined in
the  if they are the nearest neighbor.

•	{DATAONLY} is a keyword that specifies that only data values
are free to nibble into areas defined in the .
NODATA values in the input grid are not allowed to nibble into
areas defined in the  even if they are the nearest
neighbor.

•	NIBBLE allows selected areas of a grid to be assigned the value
of their nearest neighbor. This is useful for editing areas of a
grid known to be erroneous.

•	NIBBLE determines all areas in the  with the value
NODATA. The corresponding areas in the input grid will be
nibbled. Second, the internal Euclidean allocation is performed
to allocate values to the masked cells based on the Euclidean
distance. The value of the cells in the input grid which
correspond to the cells of NODATA are then nibbled away and
replaced by the value of the nearest neighbor according to
Euclidean distance.

ฉ 1995 A.C.T. GIS, Inc.

Page 119

-------
GRID Training Course

GRID Functions

September 16.1995

The THIN Function

•	Thins raster linear features in a grid.

•	THIN(, {POSITIVE I DATA}, {NOFILTER I FILTER},

{ROUND I SHARP}, {thickness})

•	 is the grid to be thinned.

•	{POSITIVE} means all cells whose VALUE is greater than 0
belong to the foreground cells; all others are background cells.

•	{DATA} means all cells whose VALUE are not NODATA are
foreground cells, and NODATA cells are background cells.

•	{NOFILTER} means no filter will be applied.

•	{FILTER} means the grid will be filtered to smooth the
boundaries between foreground and background cells. This
option will eliminate minor irregularities from the output grid.

•	{ROUND} attempts to smooth corners and junctions and is best
for vectorizing natural features such as streams or contours.

•	{SHARP} attempts to preserve rectangular corners and junctions.
This is best for vectorinzing man-made features such as streets.

•	{thickness} is the maximum thickness, in map units, of linear
features in the input grid. The default is 10 times the cell size.
Best results are obtained when the {thickness} fits the thickest
linear feature to be thinned.

•	The thinning process is built into the GRIDLINE and
STREAMLINE functions, thus eliminating the need to thin a
grid before these functions are used.

•	The FILTER options uses the algorithm from the
BOUNDARYCLEAN command to remove short linear features
extending from the major branch. It may also remove features
narrower than three cells.

ฉ 1995 A.C.T. GIS, Inc.

Page 120

-------
GRID Training Course

GRID Functions

September 16. 1995

Projecting Grids

•	Just as it is often necessary to change the map projection of a
coverage, grids must sometimes be projected since all grids
being using for raster analysis must be in the same map
projection. The PROJECT function is provided for this purpose.
Also, the ARC PROJECT command may be used to project a grid
as well.

The PROTECT Function

•	Converts a grid between two coordinate systems.

•	PROJECT(, {projection_file},

{NEAREST I BILINEAR I CUBIC}, {out_cellsize})

•	 is the grid whose coordinates are to be projected.

•	{projection_file} is the name of an ASCII text file used to define
the input and output projections. If no projection file is
specified, the user is prompted to enter the input and output
projections using subcommands just like the ARC PROJECT
command.

•	{NEAREST} means cells are resmapled using the nearest
neighbor algorithm

•	{BILINEAR} means cells are resmapled using bilinear
interpolation.

•	{CUBIC} means cells are resmapled using cubic convolution.

•	{out_cellsize} is the size in map units of the cells in the output
grid.

ฉ 1995 A.C.T. GIS, Inc.

Page 121

-------
GRID Training Course

GRID Functions

September 16. 1995

Raster to Vector Conversion

•	Coverages are the primary source for creating grids. Equally
important is the ability to convert grids into vector coverages.
This section addresses the ARC commands and GRID functions
available for raster to vector conversion.

The GRIPLINE Function

•	Converts a grid representing raster linear features into a line
coverage.

•	GRIDLINE(, {POSITIVE I DATA}, {THIN I NOTHIN},

{NOFILTER I FILTER}, {ROUND I SHARP},
{item}, {thickness}, {dangle}, {weed})

•	 is the grid to vectorize.

•	{POSITIVE} means only cell values greater than or equal to 0
will be vectorized.

•	{DATA} means all cells will be converted except those assigned
NODATA.

•	{THIN} means foreground cells will be thinned.

•	{NOTHIN} means no thinning will occur.

•	{NOFILTER} is the default and means no filter will be applied.

•	{FILTER} means the grid will be filtered to smooth boundaries.

•	{ROUND} rounds corners and junctions. This is useful for grids
representing man-made features such as streets.

•	{SHARP} preserves rectangular corners and junctions. This is
useful for grids representing natural features such as streams.

•	{item} is the item in the AAT to receive the grid cell values. If #
is entered, no item is written to the AAT.

ฉ 1995 A.C.T. GIS, Inc.

Page 122

-------
GRID Training Course					September 16. 1995

GRID Functions

The GRIDLINE Function (Continued)

•	{thickness} is the maximum thickness, in map units, of the linear
features in the grid.

•	{dangle} is the minimum length, in map units, of dangling arcs
that will be retained. The default is 0.7 times the thickness if
THIN is used, and 2 times the thickness if NOTHIN is used.

•	{weed} is specified in map units and is used to generalize arcs.
The default is 0.0.

The GRIDPOINT Function

•	Converts a grid representing raster point features to a point
coverage.

•	GRIDPOINT(, {patjtem})

•	 is the input grid.

•	{pat_item} is the item in the PAT which will hold the cell value.
If not specified

•	The points are positioned at the center of cells they represent.
Only NOD ATA cells will not be converted.

The GRIDPOLY Function

•	Converts a grid to a polygon coverage. Polygons are built from
groups of contiguous cells having the same cell value.

•	GRIDPOLY(, {weed_tolerance})

•	 is the grid to vectorize.

•	{weed_tolerance} is used to generalize arcs. The default is 0.0.

•	In most cases, the weed tolerance should be less than 2.5 times
the cell size.

ฉ 1995 A.C.T. GIS, Inc.

Page 123

-------
GRID Training Course

GRID Functions

September 16. 1995

The ARC GRID ASCII Command

•	Converts a grid into an ASCII file.

•	Usage: GRID ASCII   {item}

•	 is the grid to be converted.

•	 is the output ASCII file.

•	{item} is the name of the input grid item whose value will be
connected to the ASCII file. The item must be numeric and
defaults to VALUE.

•	GRIDASCII is useful for creating an ASCII file version of a
grid. The file is formatted as a matrix so that programming
language such as C can easily read and process the matrix to
perform operations not available within GRID. The C program
can create a new ASCII file to hold the processing results which
can be converted into a grid using the ASCIIGRID command.

The ARC GRIDLINE Command

•	Converts a grid representing raster linear features into a line
coverage.

ฎ Usage: GRIDLINE   {POSITIVE I DATA}

{NOTHIN I THIN} {NOFILTER I FILTER}
{ROUND I SHARP} {item} {thickness}
{dangle} {weed}

•	 is the grid to vectorize.

ฎ  is the output line coverage created.

•	{POSITIVE} means only cell values greater than or equal to 0
will be vectorized.

•	{DATA} means all cells will be converted except those assigned
NODATA.

ฉ 1995 A.C.T. GIS, Inc.

Page 124

-------
GRID Training Course	

GRID Functions

The ARC GRIDLINE Command (Continued)

September 16. 1995

•	{THIN} means foreground cells will be thinned.

•	{NOTHIN} means no thinning will occur.

•	{NOFILTER} is the default and means no filter will be applied.

•	{FILTER} means the grid will be filtered to smooth boundaries.

•	{ROUND} rounds corners and junctions. This is useful for grids
representing man-made features such as streets.

•	{SHARP} preserves rectangular corners and junctions. This is
useful for grids representing natural features such as streams.

•	{item} is the item in the AAT to receive the grid cell values. If #
is entered, no item is written to the AAT.

•	{thickness} is the maximum thickness, in map units, of the linear
features in the grid.

•	{dangle} is the minimum length, in map units, of dangling arcs
that will be retained. The default is 0.7 times the thickness if
THIN is used, and 2 times the thickness if NOTHIN is used.

•	{weed} is specified in map units and is used to generalize arcs.
The default is 0.0.

ฉ 1995 A.C.T. GIS, Inc.

Page 125

-------
GRID Training Course			September 16,1995

GRID Functions

The ARC GRIDPOINT Command

•	Converts a grid representing raster point features to a point
coverage.

•	Usage: GRIDPOINT   {pat_item}

•	 is the input grid to convert.

e  is the output point coverage.

•	{pat_item} is the item in the PAT which will hold the cell value.
If not specified

•	The points are positioned at the center of cells they represent.
Only NOD ATA cells will not be converted.

The ARC GRIDPOLY Command

•	Converts a grid to a polygon coverage. Polygons are built from
groups of contiguous cells having the same cell values.

•	Usage: GRIDPOLY   {weed_tolerance>

•	 is the input grid to convert.

•	 is the output polygon coverage.

•	{weed_tolerance} is used to generalize arcs. The default is 0.0.

ฉ 1995 A.C.T. GIS, Inc.

Page 126

-------
GRID Training Course

September 16. 1995

GRID Functions

Focal Functions

• Focal functions compute an output grid where the output value
at each location is a function of the input cell(s) in some
specified neighborhood of the location. The focal functions
within grid are:

FOCALVARIETY

The FOCALFLOW Function

•	Determines the flow into a cell from its immediate
neighborhood.

•	FOCALFLOW (, {thresh_value})

•	 is the grid the flow is calculated for.

•	{thresh_value} defines the threshold value which must be met or
exceeded before flow can occur. If the difference between the
value at a neighboring cell is less than or equal to the threshold,
the output will be assigned 0 for no flow.

•	The output grid is always integer.

•	The resulting value measure flow into a cell.

•	FOCALFLOW uses the immediate 3x3 cell neighborhood to
determine which of a cell's eight neighbors flows into it.

•	Many times the flow values represent fluid movement, such as
water moving across an elevation or slope surface, but can be
any user-defined movement.

FOCALFLOW	FOCALMAJORITY

FOCALMEAN	FOCALMEDIAN

FOCALRANGE FOCALSTD

FOCALMAX
FOCALMIN
FOCALSUM

ฉ 1995 A.C.T. GIS, Inc.

Page 127

-------
GRID Training Course

GRID Functions

September 16. 1995

The FOCALMATORITY Function

•	For each cell location on an input grid, finds the majority value
(the value that appears most often) within a specified
neighborhood and sends it to the corresponding cell location on
the output grid.

•	FOCALMAJORITY (, {DATA I NODATA})

•	FOCALMAJORITY (, , ,

, {DATA I NODATA})

•	FOCALMAJORITY (, , ,)

{DATA I NODATA})

•	FOCALMAJORITY (, , /

{DATA I NODATA})

•	FOCALMAJORITY (, , ,

, {DATA I NODATA})

•	FOCALMAJORITY (, , ,

, , {DATA I NODATA})

•	 is the input grid.

•	The default neighborhood is a 3x3 rectangle.

•	/ ,  defines the
shape of the neighborhood to be a donut. Cells outside the
inner radius but inside the outer radius are included in the
neighborhood processing.

•	,  defines the shape of the neighborhood as a
circle. Cells within the circle are processed as part of the
neighborhood.

•	,  defines the shape of an irregular
neighborhood based on a kernel file. The kernel file must have
the width and height (in the number of cells) listed as the first
record of the file. All subsequent lines represent the
neighborhood matrix. Cells with 0 are not processed, and all
non-zero cells are considered to be in the neighborhood.

ฉ 1995 A.C.T. GIS, Inc.

Page 128

-------
GRID Training Course

GRID Functions

September 16. 1995

The FOCALMATORITY Function (Continued)

•	, ,  defines the shape of the
neighborhood as a rectangle. Cells within the rectangle are
processed as part of the neighborhood.

•	, , , 

•	{DATA} specifies that if a cell has a value of NODATA in a
neighborhood, the NODATA will be ignored.

•	{NODATA} specifies that if a cell has a value of NODATA in a
neighborhood, the output cell being processed will be assigned
NODATA.

ฉ 1995 A.C.T. GIS, Inc.

Page 129

-------
GRID Training Course

GRID Functions

September 16. 1995

The FOCALMAX Function

•	For each cell location on an input grid, finds the highest value
within a specified neighborhood and sends it to the
corresponding cell location on the output grid.

•	FOCALMAX (, {DATA I NODATA})

•	FOCALMAX (, , ,

, {DATA I NODATA})

•	FOCALMAX (, , ,)

{DATA I NODATA})

•	FOCALMAX (, , ,

{DATA I NODATA})

•	FOCALMAX (, , , ,

{DATA I NODATA})

•	FOCALMAX (, , , ,

, {DATA I NODATA})

•	 is the input grid.

•	The default neighborhood is a 3x3 rectangle.

•	, ,  defines the
shape of the neighborhood to be a donut. Cells outside the
inner radius but inside the outer radius are included in the
neighborhood processing.

•	,  defines the shape of the neighborhood as a
circle. Cells within the circle are processed as part of the
neighborhood.

•	,  defines the shape of an irregular
neighborhood based on a kernel file. The kernel file must have
the width and height (in the number of cells) listed as the first
record of the file. All subsequent lines represent the
neighborhood matrix. Cells with 0 are not processed, and all
non-zero cells are considered to be in the neighborhood.

ฉ 1995 A.C.T. GIS, Inc.

Page 130

-------
GRID Training Course 	September 16, 1995

GRID Functions

The FOCALMAX Function (Continued)

•	, ,  defines the shape of the
neighborhood as a rectangle. Cells within the rectangle are
processed as part of the neighborhood.

•	, , , 

•	{DATA} specifies that if a cell has a value of NODATA in a
neighborhood, the NODATA will be ignored.

•	{NODATA} specifies that if a cell has a value of NODATA in a
neighborhood, the output cell being processed will be assigned
NODATA.

ฉ 1995 A.C.T. GIS, Inc.

Page 131

-------
GRID Training Course

September 16. 1995

GRID Functions

The FOCALMEAN Function

•	For each cell location on an input grid, finds the mean value
within a specified neighborhood and sends it to the
corresponding cell location on the output grid.

•	FOCALMEAN (, {DATA I NOD ATA})

•	FOCALMEAN (, , ,

, {DATA I NOD ATA})

•	FOCALMEAN (, , ,)

{DATA I NODATA})

•	FOCALMEAN (, , ,

{DATA I NODATA})

•	FOCALMEAN (, , , ,

{DATA I NODATA})

•	FOCALMEAN (, , , ,

, {DATA I NODATA})

•	FOCALMEAN (, , ,

{DATA I NODATA})

•	 is the input grid.

•	The default neighborhood is a 3x3 rectangle.

•	, ,  defines the
shape of the neighborhood to be a donut. Cells outside the
inner radius but inside the outer radius are included in the
neighborhood processing.

•	,  defines the shape of the neighborhood as a
circle. Cells within the circle are processed as part of the
neighborhood.

ฉ 1995 A.C.T. GIS, Inc.

Page 132

-------
GRID Training Course	September 16, 199$

GRID Functions

The FOCALMEAN Function (Continued)

•	,  defines the shape of an irregular
neighborhood based on a kernel file. The kernel file must have
the width and height (in the number of cells) listed as the first
record of the file. All subsequent lines represent the
neighborhood matrix. Cells with 0 are not processed, and all
non-zero cells are considered to be in the neighborhood.

•	, ,  defines the shape of the
neighborhood as a rectangle. Cells within the rectangle are
processed as part of the neighborhood.

•	, , / 

•	{DATA} specifies that if a cell has a value of NODATA in a
neighborhood, the NODATA will be ignored.

•	{NODATA} specifies that if a cell has a value of NODATA in a
neighborhood, the output cell being processed will be assigned
NODATA.

ฉ 1995 A.C.T. GIS, Inc.

Page 133

-------
GRID Training Course	September 16. 1995

GRID Functions

The FOCALMEDIAN Function

•	For each cell location on an input grid, finds the median value
within a specified neighborhood and sends it to the
corresponding cell location on the output grid.

•	FOCALMEDIAN (, {DATA I NODATA})

•	FOCALMEDIAN (, , ,

, {DATA I NODATA})

•	FOCALMEDIAN (, , ,)

{DATA I NODATA})

•	FOCALMEDIAN (, , ,

{DATA I NODATA})

•	FOCALMEDIAN (, , , ,

{DATA I NODATA})

•	FOCALMEDIAN (, , , ,

, {DATA I NODATA})

•	 is the input grid.

•	The default neighborhood is a 3x3 rectangle.

•	, ,  defines the
shape of the neighborhood to be a donut. Cells outside the
inner radius but inside the outer radius are included in the
neighborhood processing.

•	,  defines the shape of the neighborhood as a
circle. Cells within the circle are processed as part of the
neighborhood.

•	,  defines the shape of an irregular
neighborhood based on a kernel file. The kernel file must have
the width and height (in the number of cells) listed as the first
record of the file. All subsequent lines represent the
neighborhood matrix. Cells with 0 are not processed, and all
non-zero cells are considered to be in the neighborhood.

1995 A.C.T. GIS, Inc.

Page 134

-------
GRID Training Course	foptemlrer 16. 1995

GRID Functions

The FOCALMEDIAN Function (Continued)

•	/ ,  defines the shape of the
neighborhood as a rectangle. Cells within the rectangle are
processed as part of the neighborhood.

•	, , , 

•	{DATA} specifies that if a cell has a value of NODATA in a
neighborhood, the NODATA will be ignored.

•	{NODATA} specifies that if a cell has a value of NODATA in a
neighborhood, the output cell being processed will be assigned
NODATA.

ฉ 1995 A.C.T. GIS, Inc.

Page 135

-------
GRID Training Course					September 16.1995

GRID Functions

The FOCALMIN Function

•	For each cell location on an input grid, finds the minimum value
within a specified neighborhood and sends it to the
corresponding cell location on the output grid.

•	FOCALMIN (, {DATA I NODATA})

•	FOCALMIN (/ , ,

, {DATA I NODATA})

•	FOCALMIN (, , ,)

{DATA I NODATA})

•	FOCALMIN (, , /

{DATA I NODATA})

•	FOCALMIN (, , , ,

{DATA I NODATA})

•	FOCALMIN (, , , ,

, {DATA I NODATA})

•	 is the input grid.

•	The default neighborhood is a 3x3 rectangle.

•	/ ,  defines the
shape of the neighborhood to be a donut. Cells outside the
inner radius but inside the outer radius are included in the
neighborhood processing.

•	,  defines the shape of the neighborhood as a
circle. Cells within the circle are processed as part of the
neighborhood.

•	,  defines the shape of an irregular
neighborhood based on a kernel file. The kernel file must have
the width and height (in the number of cells) listed as the first
record of the file. All subsequent lines represent the
neighborhood matrix. Cells with 0 are not processed, and all
non-zero cells are considered to be in the neighborhood.

ฉ1995 A.C.T. GIS, Inc.

Page 136

-------
GRID Training Course	September 16.1995

GRID Functions

The FOCALMIN Function (Continued)

•	, ,  defines the shape of the
neighborhood as a rectangle. Cells within the rectangle are
processed as part of the neighborhood.

•	, , , 

•	{DATA} specifies that if a cell has a value of NODATA in a
neighborhood, the NODATA will be ignored.

•	{NODATA} specifies that if a cell has a value of NODATA in a
neighborhood, the output cell being processed will be assigned
NODATA.

ฉ1995 A.C.T. GIS, Inc.

Page 137

-------
GRID Training Course

GRID Functions

September 16. 1995

The FOCALRANGE Function

•	For each cell location on an input grid, finds the range of values
within a specified neighborhood and sends it to the
corresponding cell location on the output grid.

•	FOCALRANGE (, {DATA I NODATA})

•	FOCALRANGE (, , ,

, {DATA I NODATA})

•	FOCALRANGE (, , ,)

{DATA I NODATA})

•	FOCALRANGE (, , ,

{DATA I NODATA})

•	FOCALRANGE (, , , ,

{DATA I NODATA})

•	FOCALRANGE (, , , ,

, {DATA I NODATA})

•	 is the input grid.

•	The default neighborhood is a 3x3 rectangle.

•	, ,  defines the
shape of the neighborhood to be a donut. Cells outside the
inner radius but inside the outer radius are included in the
neighborhood processing.

•	,  defines the shape of the neighborhood as a
circle. Cells within the circle are processed as part of the
neighborhood.

•	,  defines the shape of an irregular
neighborhood based on a kernel file. The kernel file must have
the width and height (in the number of cells) listed as the first
record of the file. All subsequent lines represent the
neighborhood matrix. Cells with 0 are not processed, and all
non-zero cells are considered to be in the neighborhood.

ฉ 1995 A.C.T. GIS, Inc.

Page 138

-------
GRID Training Course	September 16. 1995

GRID Functions

The FOCALRANGE Function (Continued)

•	, ,  defines the shape of the
neighborhood as a rectangle. Cells within the rectangle are
processed as part of the neighborhood.

•	, , , 

•	{DATA} specifies that if a cell has a value of NODATA in a
neighborhood, the NODATA will be ignored.

•	{NODATA} specifies that if a cell has a value of NODATA in a
neighborhood, the output cell being processed will be assigned
NODATA.

ฉ 1995 A.C.T. GIS, Inc.

Page 139

-------
GRID Training Course

GRID Functions

September 16. 1995

The FOCALSTD Function

•	For each cell location on an input grid, finds the standard
deviation of values within a specified neighborhood and sends
it to the corresponding cell location on the output grid.

•	FOCALSTD (, {DATA I NODATA})

•	FOCALSTD (, , ,

, {DATA I NODATA})

•	FOCALSTD (, , ,)

{DATA I NODATA})

•	FOCALSTD (, , ,

{DATA I NODATA})

•	FOCALSTD (, , , ,

{DATA I NODATA})

•	FOCALSTD (, , , ,

, {DATA I NODATA})

•	FOCALSTD (, , ,

{DATA I NODATA})

•	 is the input grid.

•	The default neighborhood is a 3x3 rectangle.

•	/ ,  defines the
shape of the neighborhood to be a donut. Cells outside the
inner radius but inside the outer radius are included in the
neighborhood processing.

•	,  defines the shape of the neighborhood as a
circle. Cells within the circle are processed as part of the
neighborhood.

ฉ 1995 A.C.T. GIS, Inc.	Page 140

-------
GRID Training Course	

GRID Functions

The FOCALSTD Function (Continued)

September 16.1995

•	,  defines the shape of an irregular
neighborhood based on a kernel file. The kernel file must have
the width and height (in the number of cells) listed as the first
record of the file. All subsequent lines represent the
neighborhood matrix. Cells with 0 are not processed, and all
non-zero cells are considered to be in the neighborhood.

•	, ,  defines the shape of the
neighborhood as a rectangle. Cells within the rectangle are
processed as part of the neighborhood.

•	, , , 

•	{DATA} specifies that if a cell has a value of NODATA in a
neighborhood, the NODATA will be ignored.

•	{NODATA} specifies that if a cell has a value of NODATA in a
neighborhood, the output cell being processed will be assigned
NODATA.

ฉ 1995 A.C.T. GIS, Inc.

Page 141

-------
GRID Training Course

GRID Functions

September 16. 1995

The FOCALSUM Function

•	For each cell location on an input grid, finds the sum of values
within a specified neighborhood and sends it to the
corresponding cell location on the output grid.

•	FOCALSUM (, {DATA I NODATA})

•	FOCALSUM (, , ,

, {DATA I NODATA})

•	FOCALSUM (, , ,)

{DATA I NODATA})

•	FOCALSUM (, , ,

{DATA I NODATA})

•	FOCALSUM (, , , ,

{DATA I NODATA})

•	FOCALSUM (, , , ,

, {DATA I NODATA})

•	FOCALSUM (, , ,

{DATA I NODATA})

•	 is the input grid.

•	The default neighborhood is a 3x3 rectangle.

•	, ,  defines the
shape of the neighborhood to be a donut. Cells outside the
inner radius but inside the outer radius are included in the
neighborhood processing.

•	,  defines the shape of the neighborhood as a
circle. Cells within the circle are processed as part of the
neighborhood.

ฉ 1995 A.C.T. GIS, Inc.

Page 142

-------
GRID Training Course			September 16. 1995

GRID Functions

The FOCALSUM Function (Continued)

•	/  defines the shape of an irregular
neighborhood based on a kernel file. The kernel file must have
the width and height (in the number of cells) listed as the first
record of the file. All subsequent lines represent the
neighborhood matrix. Cells with 0 are not processed, and all
non-zero cells are considered to be in the neighborhood.

•	, ,  defines the shape of the
neighborhood as a rectangle. Cells within the rectangle are
processed as part of the neighborhood.

•	, , / 

•	{DATA} specifies that if a cell has a value of NODATA in a
neighborhood, the NODATA will be ignored.

•	{NODATA} specifies that if a cell has a value of NODATA in a
neighborhood, the output cell being processed will be assigned
NODATA.

ฉ 1995 A.C.T. GIS, Inc.

Page 143

-------
GRID Training Course

GRID Functions

September 16. 1995

The FOCALVARIETY Function

•	For each cell location on an input grid, finds the number of
unique values within a specified neighborhood and sends it to
the corresponding cell location on the output grid.

•	FOCALVARIETY (, {DATA I NOD ATA})

•	FOCALVARIETY (, , ,

, {DATA I NODATA})

•	FOCALVARIETY (, , ,)

{DATA I NODATA})

•	FOCALVARIETY (, , ,

{DATA I NODATA})

•	FOCALVARIETY (, , , ,

{DATA I NODATA})

•	FOCALVARIETY (, , , ,

, {DATA I NODATA})

•	 is the input grid.

•	The default neighborhood is a 3x3 rectangle.

•	, ,  defines the
shape of the neighborhood to be a donut. Cells outside the
inner radius but inside the outer radius are included in the
neighborhood processing.

•	,  defines the shape of the neighborhood as a
circle. Cells within the circle are processed as part of the
neighborhood.

•	,  defines the shape of an irregular
neighborhood based on a kernel file. The kernel file must have
the width and height (in the number of cells) listed as the first
record of the file. All subsequent lines represent the
neighborhood matrix. Cells with 0 are not processed, and all
non-zero cells are considered to be in the neighborhood.

ฉ 1995 A.C.T. GIS, Inc.

Page 144

-------
GRID Training Course

September 16.1995

GRID Functions

The FOCALVARIETY Function (Continued)

•	, ,  defines the shape of the
neighborhood as a rectangle. Cells within the rectangle are
processed as part of the neighborhood.

•	, , / 

•	{DATA} specifies that if a cell has a value of NODATA in a
neighborhood, the NODATA will be ignored.

•	{NODATA} specifies that if a cell has a value of NODATA in a
neighborhood, the output cell being processed will be assigned
NODATA.

ฉ 1995 A.C.T. GIS, Inc.

Page 145

-------
GRID Training Course

GRID Functions

September 16. 1995

The Zonal Functions

•	Zonal functions create an output grid on which the computation
of the desired function occurs on the cell values from the input
value grid that intersect or fall within each zone in the specified
input zone grid.

•	The input zone grid is only used to define the size, shape, and
location of each zone.

•	The input value grid is used to identify the values to be used in
the evaluation within the zone.

•	Zonal functions compute statistics or identify features on the
values from the value grid that intersect the zones defined by
values of the zone grid.

•	The following section presents a description and usage of each
zonal function.

The ZONALAREA Function

•	Calculates the area of each zone in the input grid within the
analysis window.

•	Usage: (F) ZONALAREA ()

The ZONALCENTROIP Function

•	Creates a grid of cells locating the centroids of each zone of an
input grid.

•	Usage: (I) ZONALCENTROID ()

ฉ 1995 A.C.T. GIS, Inc.

Page 146

-------
GRID Training Course	September 16. 1995

GRID Functions

The ZONALFILL Function

•	Fills zones using the minimum cell value from a weight grid,
along the zone boundary.

•	Usage: (I) ZONALFILL (, )

The ZONALGEOMETRY Function

•	Calculates for each zone of the input grid its area, perimeter,
thickness, and the characteristics of ellipse and records them in
the output INFO table.

•	Usage: (T) ZONALGEOMETRY (, {geometry_type},

{max_thickness})

The ZONALMATORITY Function

•	Records in each output cell the majority value (the value that
occurs most often) of all cells in the  that belongs
to the same zone as the output cell. Zones are identified by the
values of the cells in the input .

•	Usage: (*) ZONALMAJORITY (, ,

{DATA I NOD AT A})

The ZONALMAX Function

•	Records in each output cell the maximum value of all cells in the
 that belongs to the same zone as the output cell.
Zones are identified by the values of the cells in the input
.

•	Usage: (*) ZONALMAX (, ,

{DATA I NODATA})

ฉ 1995 A.C.T. GIS, Inc.

Page 147

-------
GRID Training Course

GRID Functions

fiftptftmber 16. 1995

The ZONALMEAN Function

•	Records in each output cell the mean value of all cells in the
 that belongs to the same zone as the output cell.
Zones are identified by the values of the cells in the input
.

•	Usage: (F) ZONALMEAN (, /

{DATA I NODATA})

The ZONALMEDIAN Function

•	Records in each output cell the median value of all cells in the
 that belongs to the same zone as the output cell.
Zones are identified by the values of the cells in the input
.

•	Usage: (*) ZONALMEDIAN (, ,

{DATA I NODATA})

The ZONALMIN Function

•	Records in each output cell the minimum value of all cells in the
 that belongs to the same zone as the output cell.
Zones are identified by the values of the cells in the input
.

•	Usage: (*) ZONALMIN (, ,

{DATA I NODATA})

The ZONALPERIMETER Function

o Calculates the perimeter of each zone in the input grid within
the analysis window.

•	Usage: (I) ZONALPERIMETER ()

ฉ 1995 A.C.T. GIS, Inc.

Page 148

-------
GRID Training Course	September 16. 1995

GRID Functions

The ZONALRANGE Function

•	Records in each output cell the range of values of all cells in the
 that belongs to the same zone as the output cell.
Zones are identified by the values of the cells in the input
.

•	Usage: (*) ZONALRANGE (, /

{DATA I NODATA})

•	Usage: (*) ZONALRANGE (, ,

{DATA I NODATA})

The ZONALSTATS Function

•	Records in an output INFO table the mean, minimum,
maximum, range, sum, standard deviation, variety, majority, and
median of the values of all cells in the value grid that belong to
the same zone. Zones are identified by the values of the cells in
the input zone grid.

•	Usage: (T) ZONALSTATS (, ,

{stats_name}, {DATA I NODATA})

The ZONALSTD Function

•	Records in each output cell the standard deviation of all cells in
the  that belongs to the same zone as the output
cell. Zones are identified by the values of the cells in the input
.

•	Usage: (F) ZONALSTD (, /

{DATA I NODATA})

ฉ 1995 A.C.T. GIS, Inc.

Page 149

-------
GRID Training Course	September 16. 1995

GRID Functions

The ZONALSUM Function

•	Records in each output cell the sum of all cells in the
 that belongs to the same zone as the output cell.
Zones are identified by the values of the cells in the input
.

•	Usage: (*) ZONALSUM (, /

{DATA I NODATA})

The ZONALTHICKNESS Function

•	Calculates for each zone on an input grid the deepest or thickest
point within the zone from its surrounding cells.

•	Usage: (I) ZONALTHICKNESS (/{max_thickness})

The ZONALVARIETY Function

•	Records in each output cell the variety (the number of unique
values) of all cells in the  that belongs to the same
zone as the output cell. Zones are identified by the values of the
cells in the input .

•	Usage: (I) ZONALVARIETY (, /

{DATA I NODATA})

ฉ 1995 A.C.T. GIS, Inc.

Page 150

-------
GRID Training Course

September 16. 1995

Surface Analysis

Surface Analysis

•	Surfaces can be stored as integer or floating point grids.

•	The surface view of a grid considers the value of each cell as a
point, at the center of the cell. The value of other locations
within the same cell can be interpolated from the cell center and
the center of neighboring cells.

•	GRID provides four functions which generate floating point
grids from a point data set. This point data set can be a point
coverage or an ASCII file of x,y,z values in ARC GENERATE
format. The points can be randomly distributed in space.

•	The four surface generators are inverse distance weighted
interpolation (IDW), trend surface interpolation, kriging, and
spline.

•	The distribution of sample points and the type of surface you
are trying to generate (simulate) determines which surface
generation method to use.

ฉ 1995 A.C.T. GIS, Inc.

Page 151

-------
GRID Training Course

September 16. 1995

Surface Analysis

The IDW Function

•	Performs an inverse distance weighted interpolation on a point
data set.

•	IDW (, {spot_item},

{barriers}, {power}, {SAMPLE, {num_points},

{max_radius}}, {cellsize}, {xmin, ymin, xmax, ymax})

•	IDW (, {spot_item}, {barriers},

{power}, {RADIUS, {radius}, {min_points}},

{cellsize}, {xmin, ymin, xmax, ymax})

•	IDW allows you to control the significance of known points
upon the interpolated values, based upon their distance from
the output point. The {power} option can be used to change the
interpolation from local to global. A larger power will result in
lesser influence from surrounding points.

•	The output values for a cell using IDW is limited to the range of
values used to interpolate.

•	The influence of an input point on an interpolated value is
isotropic. Since the influence of an input point on an
interpolated value is distance related, IDW is not ridge
preserving.

•	The best results from IDW are obtained when sampling is
sufficiently dense in regard to the local variation you are
attempting to simulate. If the input points are sparse or very
uneven, the results may not sufficiently represent the desired
surface.

ฉ 1995 A.C.T. GIS, Inc.

Page 152

-------
GRID Training Course

September 16.1995

Surface Analysis

The KRIGING Function

•	Interpolates a grid from a set of points using kriging.

•	Usage: (F) KRIGING (, {spot_item},

{barrier_cover I barrier_file},

{BOTH I GRAPH I GRID}, {output_variance},

{method}, {SAMPLE, {num_points}, {max_radius}},
{cellsize}, {xmin, ymin, xmax, ymax})

•	KRIGING (, {spot_item},

{barrier_cover I barrier_file},

{BOTH I GRAPH I GRID}, {output_variance},

{method}, {RADIUS, {radius}, {min_points}},

{cellsize}, {xmin, ymin, xmax, ymax})

•	Kriging is based on the regionalized variable theory that
assumes that the spatial variation in the phenomenon
represented by the z values is statistically homogeneous
throughout the surface.

•	Each kriging method uses a mathematical function to model the
spatial variation in z values within the input sample points. The
variations are measured using semi-variance.

•	The key to reviewing semi-variance is the creation of a semi-
variogram. This can be done with the KRIGING GRAPH and
BOTH options and using the Arcplot SEMIVARIOGRAM
command to review the semi-variogram.

ฉ 1995 A.C.T. GIS, Inc.

Page 153

-------
GRID Training Course

September 16. 1995

Surface Analysis

The TREND Function

•	Performs a trend interpolation on a point data set.

•	Usage: (F) TREND (, {spot_item},

{order}, {LINEAR I LOGISTIC},

{cellsize}, {xmin, ymin, xmax, ymax})

•	The trend surface interpolator uses a polynomial regression to
fit a least-squares surface to the input points. The trend
interpolator allows the user control over the order of the
polynomial used to fit the surface.

•	A first-order trend surface interpolation performs a least-
squares fit of a plane to the set of input points.

•	As the order of the polynomial is increased, the surface becomes
progressively more complex.

•	Trend surface interpolation creates smooth surfaces. The
surface generated will seldom pass through the original data
points since it performs a best fit for the entire surface.

•	The most common order of polynomials is 1 to 3.

The SPLINE Function

•	Performs a two-dimensional minimum curvature spline
interpolation on a point data set resulting in a smooth surface
that passes exactly through the input points.

•	Usage: (F) SPLINE (, {spot_item},

{REGULARIZED I TENSION}, {weight}, {num_points},
{cellsize}, {xmin, ymin, xmax, ymax})

•	Spline is also referred to as thin plate interpolation. It ensures a
smooth and continuous surface together with first-derivative
surfaces.

ฉ1995 A.C.T. GIS, Inc.

Page 154

-------
GRIDTraininp Course

September 16. 1995

Surface Analysis

Surface Defined Grids

•	Slope identifies the maximum rate of change in value from each
cell to its neighbors. An output slope grid can be calculated as
percent slope or degree of slope.

•	Aspect identifies the down-slope direction of the maximum rate
of change in value from each cell to its neighbors. The output
will be a grid of compass directions of the aspect (aspect can be
thought of as the slope direction).

•	Analytical hillshading is a way to determine the hypothetical
illumination of a surface for analytical or graphical reasons.

The SLOPE Function

•	Identifies the rate of maximum change in z values from each
cell.

•	SLOPE (, {DEGREE I PERCENTAGE})

•	SLOPE (, , {DEGREE I PERCENTAGE})

•	 is the input surface.

•	{DEGREE} calculates slope in degrees.

•	{PERCENTAGE} calculates slope as the percent rise.

•	 is the number of ground x,y units in one surface z
unit. Its use is essential when surface z units are expressed in
units different from the ground units.

•	If the center of a cell in the immediate 3x3 neighborhood is
NODATA, the output is NODATA.

ฉ 1995 A.C.T. GIS, Inc.

Page 155

-------
GRID Training Course

September 16. 1995

Surface Analysis

The ASPECT Function

•	Identifies the direction of maximum rate of change in the z
value from each cell.

•	ASPECT ()

•	Aspect is expressed in positive degrees from 0 to 360, measured
clockwise from north.

•	Cells in the input of zero slope are assigned an aspect of -1.

•	If the center of a cell in the immediate 3x3 neighborhood is
NOD ATA, the output is NOD ATA.

•	If any neighborhood cells are NODATA, they are assigned the
values of the center cell then the aspect is computed.

ฉ 1995 A.C.T. GIS, Inc.

Page 156

-------
GRID Training Course

September 16.1995

Surface Analysis

The HILLSHADE Function

•	Creates a shaded relief grid from a grid by considering the
illumination angle and shadows.

•	HILLSHADE (, {azimuth}, {altitude},

{ALL I SHADE I SHADOW}, {z_factor})

•	 is the input grid.

•	{azimuth} is the azimuth angle of the light source measured
clockwise from 0 to 360 degrees from north. The default is 315.

•	{altitude} is the slope or angle of the illumination source above
the horizon measured from 0 to 90 degrees.

•	{ALL} considers both local illumination angles and shadows.
Output values range from 0 to 255.

•	{SHADE} considers local illumination angles where shadows are
not considered. Output values range from 0 to 255.

•	{SHADOW} creates a binary grid (1 is light and 0 is shadow).

•	 is the number of ground x,y units in one surface z
unit. Its use is essential when surface z units are expressed in
units different from the ground units.

ฉ 1995 A.C.T. GIS, Inc.

Page 157

-------
GRID Training Course

September 16.1995

Surface Analysis

The SAI Command

•	Creates an output grid containing a slope-aspect index, or a
lookup table of hypothetical illumination to be used for
displaying such as grid.

•	Usage: SAI   {z_factor}

Usage: SAI  {azimuth} {altitude}

•	 is a surface grid.

•	 is the output slope-aspect index grid.

•	 the name of the output colormap file based
on azimuth and altitude.

•	{azimuth} is the angle of the illumination source from north,
from 0 to 360 degrees measured clockwise, where north is 0
degrees and east is 90 degrees. The default is 315 degrees.

•	{altitude} is the angle of the illumination source above the
horizon, 0 to 90 degrees where 45 is the default.

•	A sample output of Mount St. Helens created with SAI was
created using the command "gridpaint surfsai # # #
surfsai.cmf".



ฉ 1995 A.C.T. GIS, Inc.

Page 158

-------
GRID Training Course			September 16.1995

Distance Functions

Distance Functions

• The following table presents the distance functions within
GRID:

Distance Function

Description

CORRIDOR

Records for each cell location in the sum of accumulative
costs for two input accumulative-cost grids.

COST ALLOCATION

Identifies for each cell the zone of each source cell that could
be reached with the least accumulative cost.

COSTBACKLINK

Defines the neighbor that is the next cell on the least-
accumulative cost path from a cell to a set of source cells.

COSTDISTANCE

Calculates for each cell the least-accumulative-cost distance
over a cost surface to a source cell or a set of source cells.

COSTPATH

Produces an output grid that records the least-cost path(s)
from selected cells in the input grid to the closest source cell
defined within the accumulative-cost grid in terms of cost
distance.

EU ALLOCATION

Calculates for each cell the zone of the source cell (in
Euclidean distance).

EUDIRECTION

Calculates the direction in degrees that each cell center is
from the closest source. The output values are based on
compass direction, with 0 degrees being reserved for the
source cell.

EUDISTANCE

Calculates for each cell the Euclidean distance to the closest
cell.

PATHDISTANCE

Calculates for each cell the least-accumulative-cost distance
over a cost surface from a source cell or set of source cells
which accounting for surface distance and horizontal and
vertical cost factors.

ฉ1995 A.C.T. GIS, Inc.

Page 159

-------
GRID Training Course

September 16.1995

Surface Hydrologic Analysis

Surface Hvdrologic Analysis

•	The shape of a surface determines how water will flow across it.

•	Using a DEM as input, it is possible to delineate a drainage
system and then quantify the characteristics of that system.

•	The GRID tools let you determine for any location on a surface,
the upslope area contributing to that point, and the downslope
path water would flow.

•	Watersheds and stream networks created from DEMs using
GRID are the primary inputs to most surface hydrologic models.

•	Surface hydrologic models can determine the height, timing,
and inundation of a flood, as well as locating areas contributing
to pollutants in a stream, or predicting the effects of altering the
landscape.

DEMs

•	A DEM is a raster representation of a continuous surface,
usually referring to the surface of the Earth. The accuracy of a
DEM depends on how it was sampled, the spacing of points,
and the data type (integer or floating point).

•	Errors in DEMs are usually classified as sinks or peaks.

•	A sink is an area surrounded by higher elevation values.

•	A peak is an area surrounded by lower elevation values.

•	Errors such as sinks should be removed before attempting to
derive surface information since flow direction can be adversely
affected.

•	The number of sinks in a DEM is usually higher when the
resolution becomes coarser. Sinks can also be caused by stored
surface values as integers.

ฉ 1995 A.C.T. GIS, Inc.

Page 160

-------
GRID Training Course					September 16.1995

Surface Hydrologic Analysis

Creating a Depressionless DEM

•	Sinks can be located using the SINK function, and can be filled
with the GRID FILL command.

The SINK Function

•	Creates a grid, identifying all sinks (areas of internal drainage).

•	SINK ()

•	 is a grid showing the direction of flow out of each
cell. It can be created with the FLOWDIRECTION function.

•	The output of the SINK function is an integer grid with each
sink being assigned a unique value (numbered between 1 and
the total number of sinks).

•	Sinks in elevation data are commonly due to errors in the data.
They should be removed in order to be able to create an accurate
representation of flow direction.

•	The example below presents the creation of a sink grid:

Grid: sinkgrid = sink(flowdiretion(elev_grid))

•	It is sometimes useful to know the depth of a sink or group of
sinks. This information can be used to determine an
appropriate {z_limit} for the FILL function. A grid of sinks
coded with depth can be created by first running the SINK
function to locate sinks in a grid:

Grid: flowdir = (flowdiretion(demlat)

Grid: sinkgrid = sink(flowdir)

Then use the WATERSHED function to create a grid of the
contributing area of each sink:

Grid: sink_areas = watershed(flowdir, sinkgrid)

ฉ 1995 A.C.T. GIS, Inc.

Page 161

-------
GRID Training Course	September 16. 1995

Surface Hydrologic Analysis

The SINK Function (Continued)

Then create a grid of minimum elevation in the watershed of
each sink:

Grid: sink_min = zonalmin(sink_areas/ demlat)

Then create a grid of maximum elevation in the watershed of
each sink:

Grid: sink_max = zonalfill(sink_areas, demlat)

Then subtract the minimum value from the maximum value to
find the depth:

Grid: sink_depth = sink_max - sink_min

ฉ 1995 A.C.T. GIS, Inc.

Page 162

-------
GRID Training Course

September 16. 1995

Surface Hydrologic Analysis

The FILL Command

•	Fills sinks (areas of internal drainage) or levels peaks in a
continuous grid to remove small imperfections in the data.

•	FILL   {SINK I PEAK}

{z_limit} {out_dir_grid}

•	 is the surface grid.

•	 is the grid that has its sinks filled or peaks cut.

•	{SINK} specifies that all sinks that are less than {z_limit} lower
than their lowest adjacent neighbor will be filled to the height
of their pour point.

•	{PEAK} specifies that all peaks less than the {z_limit} that are
higher than the highest adjacent neighbor will be cut down to
the height of their neighbor.

•	{z_limit} is the maximum difference between a sink and its pour
point or a peak and its highest adjacent neighbor. {z_limit} is
expressed in map units and can be thought of as the depth of all
sinks that will be removed.

•	{out_dir_grid} is an optional output grid that stores the flow
direction from each cell to the steepest downslope neighbor.
This is the same as the output of the FLOWDIRECTION
function.

ฉ1995 A.C.T. GIS, Inc.

Page 163

-------
GRID Training Course

September 16. 1995

Surface Hydrologic Analysis

The FLOWDIRECTION Function

•	Determines the direction of flow from every cell to its steepest
downslope neighbor.

•	FLOWDIRECTION (, {o_drop_grid},

{NORMAL I FORCE})

•	 is the input surface grid representing elevations.

•	{o_drop_grid} is an optional output grid showing the ratio of
maximum change in elevation from each cell along the direction
of flow, to the path length between centers of cells, expressed in
percents.

•	{NORMAL} specifies if the maximum drop on the inside of an
edge cell is greater than 0, the flow direction will be determined
as usual. Otherwise, flow direction will be toward the edge.

•	{FORCE} specifies that all cells at the edge of the surface grid
will flow outward from the surface grid.

•	The output is a grid with values from 1 to 255

•	Downstream tracing can be performed using the flow direction
grid as a backlink grid for input into the COSTPATH function.

•	If all neighbors are higher than the processing cell, the
neighborhood is enlarged until a steepest descent is found.

•	If all neighbors are higher than the processing cell, it will be
considered noise and filled to the lowest value of its neighbors
and have a flow direction towards this cell.

ฉ 1995 A.C.T. GIS, Inc.

Page 164

-------
GRID Training Course	September 16. 1995

Surface Hydrologic Analysis

The FLOW ACCUMULATION Function

•	Creates a grid of accumulated flow to each cell by accumulating
the weight of all cells that flow into each downslope cell.

•	FLOWACCUMULATION (, {weight_grid})

•	 is the input grid showing direction of flow out of
each cell.

•	{weight_grid} is the weight assigned to each cell. If not
specified, a default weight of one will be applied to each cell.
For each cell in the output grid, the result will be the number of
cells that flow into it.

•	The {weight_grid} could be a continuous grid representing
rainfall during a given storm. FLOWACCUMULATION could
be used to determine how much rain has fallen within a given
watershed. The output would be the amount of rain that has
that would flow through each cell, assuming all rain became
runoff.

•	Output cells with a flow accumulation of 0 are local topographic
highs and are used to identify ridges.

•	Cells of high accumulated flow are areas of concentrated flow
and may be used to identify stream channels.

ฉ 1995 A.C.T. GIS, Inc.

Page 165

-------
GRID Training Course

September 16. 1995

Surface Hydrologic Analysis

The FLOWLENGTH Function

•	Calculates upstream and downstream distance along a flow path
for each cell.

•	FLOWLENGTH (, {weight_grid},

{DOWNSTREAM I UPSTREAM})

•	 is a grid indicating direction of flow.

•	{weight_grid} is a grid defining impedance or resistance to flow
through each cell. The value at each cell represents the cost per
unit distance of moving through the cell. Each cell location is
multiplied by the cell resolution to obtain the total cost of
passing through the cell.

•	{DOWNSTREAM} calculates the downslope distance along the
flow path from each cell to a sink or outlet on the edge of a grid.

•	{UPSTREAM} calculates the upstream distance along the flow
path, from each cell to the top of the drainage divide.

•	FLOWLENGTH is used to calculate the length of the longest
flow path within a given basin. The measure is often used to
calculate the time of concentration of a basin (using the
UPSTREAM option).

•	FLOWLENGTH can also be used to create distance-area
diagrams of hypothetical rainfall/runoff events using the
weight_grid as an impedance to movement downslope.

ฉ 1995 A.C.T. GIS, Inc.

Page 166

-------
GRID Training Course

September 16. 1995

Surface Hydrologic Analysis

The BASIN Function

•	Creates a grid delineating all drainage basins within the
analysis window.

•	BASIN ()

•	 is a grid showing direction of flow out of each cell.
It can be created using the FLOWDIRECTION function.

•	Best results are obtained when the NORMAL option is used
with the FLOWDIRECTION function.

•	All cells will belong to a basin, even if the basin is made up of
one cell.

•	Basins are identified by ridge lines between basins.

•	The drainage basins are created by locating the pour points at
the edge of the analysis window (where water would pour out
of the grid) as well as sinks, then identifying the contributing
area above each pour point.

ฉ 1995 A.C.T. GIS, Inc.

Page 167

-------
GRID Training Course

September 16. 1995

Surface Hydrologic Analysis

The WATERSHED Function

•	Determines the contributing area above a set of cells in a grid.

•	WATERSHED (, )

•	 is a grid showing direction of flow out of each cell.
It can be created using the FLOWDIRECTION function.

•	 is a grid representing cells above which the
contributing area, or catchment, will be determined. All cells
that are not NODATA will be used as source cells.

•	 can be created interactively using the
SELECTPOINT function. By using the elevation grid as the
input to SELECTPOINT, the value of the resulting watersheds
will be equal to the elevation of the pour point of each
watershed.

•	A pour point is the point at which water flows out of an area.

ฉ 1995 A.C.T. GIS, Inc.

Page 168

-------
GRID Training Course	.	September 16. 1995

Surface Hydrologic Analysis

The STREAMLINK Function

•	Assigns unique values to selections of a raster linear network
between intersections.

•	STREAMLINK(/ )

•	 a grid representing a raster linear network.

•	 is a grid showing direction of flow out of each cell. It
can be created using the FLOWDIRECTION function.

•	Links are the sections of a stream channel connecting two
successive junctions, a junction and the outlet, or a junction and
the drainage divide.

The STREAMLINE Function

•	Converts a grid representing a raster linear network into a line
coverage.

•	STREAMLINE (, , {out_item}, {weed})

•	 a grid representing a raster linear network.

•	 is a grid showing direction of flow out of each cell. It
can be created using the FLOWDIRECTION function.

•	{out_item} is the output cover's A AT item to be assigned the
attribute of the grid cells. By default, cover-id receives the
attribute.

•	{weed} is the weed tolerance in map units for generalization of
arcs.

•	The arcs of the output cover will point downstream.

•	STREAMLINE is a vectorization program primarily for
vectorizing stream networks.

ฉ 1995 A.C.T. GIS, Inc.

Page 169

-------
GRID Training Course

September 16. 1995

Surface Hydrologic Analysis

The STREAMORDER Function

•	Assigns a numeric order to segments of a grid representing
branches of a linear network.

•	STREAMORDER (, ,

{STRAHLER I SHREVE})

•	 a grid representing a raster linear network.

•	 is a grid showing direction of flow out of each cell. It
can be created using the FLOWDIRECTION function.

•	{STRAHLER} calculates stream order as increasing only when
two streams on the same order intersect. Streams with no
tributaries are considered first order streams.

•	{SHREVE} calculates stream order by magnitude. All links with
no tributaries are assigned a magnitude of 1. Magnitudes are
additive downslope. When two links intersect, their
magnitudes are added and assigned to the downstream link.

The SNAPFOUR Function

•	Snaps selected pour points to the cell of highest flow
accumulation within a specified neighborhood.

•	SNAPPOUR (<* I source_grid I point_file>, ,

{snap_distance})

•	SNAPPOUR is used to ensure selection of points of high
accumulated flow when delineating drainage basins using the
WATERSHED function.

ฉ 1995 A.C.T. GIS, Inc.

Page 170

-------
GRID Training Course

September 16. 1995

Groundwater Advection and Dispersion Modeling

•	The functions DARCYFLOW, PARTICLETRACK, and
POROUSPUFF can be used to perform rudimentary advection-
dispersion modeling of constituents in groundwater.

The DARCYFLOW Function

•	Calculates the groundwater volume balance residual for steady
flow in an aquifer and the seepage velocity vector (expressed as
grids of direction and magnitude) for each cell using Darcy's
law.

•	DARCYFLOW (/ ,

/ /
{out_direction_grid}, {out_magnitude_grid})

•	DARCYFLOW is used to check the consistency of groundwater
datasets and to generate grids of groundwater flow vectors.

The PARTICLETRACK Function

•	Calculates the path of a particle through a velocity field,
returning an ASCII file of particle tracking data and optionally a
coverage of track information.

•	PARTICLETRACK (,

, <* I x,y>, {step_length}, {time}
{out_track_coverage})

The POROUSPUFF Function

•	Calculates the time-dependent, two-dimensional concentration
distribution in mass per volume of a solute introduced
instantaneously and at a discrete point into a vertically mixed
aquifer.

•	POROUSPUFF (, ,

, / {time},

{longitudinal_dispersivity}, {dispersivity_ratio}/
{retardation_factor}, {decay_coefficient})

ฉ 1995 A.C.T. GIS, Inc.

Page 171

-------
GRID Training Course

September 16. 1995

Visibility Functions

TheVISDECODE Command

•	Returns a list of observation points that can be seen by cell
locations within a specified value in the VALUE item of the
output grid from the VISIBILITY function.

•	VISDECODE 

TheVISENCODE Command

•	Returns the VISIBLE-CODEs or values that are assigned to each
cell location on the output grid created by the VISIBILITY
function which can be seen by up to 16 specified observation
points.

•	VISENCODE 

The VISIBILITY Function

•	Performs visibility analysis on a grid by determining how many
observation points can be seen from each cell location of the
input grid, or which cell locations can be seen by each
observation point.

•	VISIBILITY (, , {POINT I LINE}, {FREQUENCY I
OBSERVER}, {horizon_tolerance}

ฉ 1995 A.C.T. GIS, Inc.

Page 172

-------
GRID Training Course

September 16. 1995

Grid Stacks

•	A grid stack consists of an ordered set of spatially overlapping
grids. Stacks are created with the GRID MAKESTACK
command.

•	Multivariate raster data are stored within grid as a stack
consisting of a series of overlapping grids referred to as layers.

•	A stack is treated as a single entity for multivariate analysis.

•	A stack has a map extent or BND, a cell size, a data type, and a
projection.

•	Each layer in a stack has an index number indicating its order in
the stack. The grids that make up the stack must be in the same
workspace.

•	A stack is stored in a directory structure similar to a grid or
coverage. The are two files in the stack directory: an external
STK file and an ASCII PRJ file. The actual grids in the stack are
not stored in the stack directory.

•	The STK table stores the names of the grids in the stack and
their corresponding index value. The table has two items:
INDEX (for the layer number) and GRID (the grid name).

ฉ 1995 A.C.T. GIS, Inc.

Page 173

-------
GRID Training Course					September 16. 1995

Grid Stacks (Continued)

The MAKESTACK Command

•	Generates a grid stacks from a set of grids.

•	Usage: MAKESTACK  LIST 

•	Usage: MAKESTACK  FILE 

•	 is the grid stack created.

•	LIST  is the syntax for listing the grids which define
the stack.

•	FILE  indicates a file will be used to generate the
stack. The file must begin with a record indicating the number
of grids in the stack followed by each grid in the stack listed one
line after another.

•	All grids to be included in the stack must exist in the current
workspace.

•	Multiple stacks in the same workspace can share the same
grid(s).

The STACKSHADE Command

•	Displays the layers (grids) of a stack using the current shadeset.

•	Usage: STACKSHADE 

{IDENTITY I LINEAR I EQUALAREA I remap_table}

{n_pages}

•	 is the grid stack to display.

•	{IDENTITY} is the default. It means no stretch is applied and
the cell value will be used as the shade symbol.

•	{ LINEAR} means a linear stretch will be applied. Values are
stretched from 0 to 255.

•	{EQUALAREA} means an equal-area stretch will be applied.
Values are stretched from 0 to 255.

ฉ 1995 A.C.T. GIS, Inc.

Page 174

-------
GRID Training Course	September 16. 1995

Grid Stacks (Continued)

The STACKSHADE Command

•	{remap_table} means a remap table will be used to determine
the symbol to be used to display each cell value.

•	{n_pages} is the number of sequential displays in which the
stack's layers will be drawn. The default is 1.

•	Each layer of a stack is given an equal area within the
MAPLIMITS.

•	A stack consisting of continuous data must be displayed in a
continuous color scale. RAINBOW.SHD may be used if colors
are desired.

The COPYSTACK Command

•	Copies a stack, including its component grids, to a new stack.

•	Usage: COPYSTACK  {to_stack}

{OLDGRIDNAME I NEWGRIDNAME}

•	 is the stack to copy.

•	{to_stack} is the name of the new stack.

•	{to_stack} is the new stack.

•	{OLDGRIDNAME} is a keyword indicating the stack and its
component grids are copied into a workspace with their original
names.

•	{NEWGRIDNAME} is a keyword indicating the stack and its
component grids are copied into a workspace and assigned new
names. The component grids are renamed to the name of the
new stack with "cn" appended to the end of the grid name
where n is the stack layer number.

•	Stacks can be copied to the same workspace only if the
{NEWGRIDNAME} option is used.

ฉ1995 A.C.T. GIS, Inc.

Page 175

-------
GRID Training Course			September 16. 1995

Grid Stacks (Continued)

The DROFFROMSTACK Command

•	Drops one or more grids from a stack.

•	Usage: DROPFROMSTACK  NAME 

Usage: DROPFROMSTACK  INDEX 

•	 is the name of the stack the layer(s) will be eliminated
from.

•	NAME  indicates the grids will be dropped using
their grid names.

•	INDEX  indicates the grids will be dropped
using their index or layer numbers.

•	Any layer in the stack may be dropped.

•	The BND and cell size of the stack will be updated to reflect the
remaining layers in the stack.

The STACKSTATS Command

•	Calculates the statistics for the layers in a stack.

•	Usage: STACKSTATS  {out_data_file} {BRIEF I DETAIL)

•	 is the input stack.

•	{out_data_file} is an optional file where the results are stored.
By default, the statistics are displayed on the screen and not
written to a file unless specified.

•	{BRIEF I DETAIL} determines whether just statistics (BRIEF) or
statistics and the covariance and correlation matrices are also
determined (DETAIL).

•	Statistics include the minimum, maximum, mean, and standard
deviation of the layers.

ฉ 1995 A.C.T. GIS, Inc.

Page 176

-------
GRID Training Course	September 16.1995

AML Directives

User Environment Directives - &DESCRIBE

•	Stores information about a specified geo_dataset in AML
reserved variables.

•	Usage: &describe 

•	 is any ARC/INFO coverage, grid, grid stack,
image, tin, or lattice

•	&describe does not display information to the terminal like the
ARC DESCRIBE command. Instead, it sets a series of reserved
variables holding information about the specified geo_dataset.

•	Reserved variable prefixes are DSC$ for coverage descriptions,
GRD$ for grid descriptions, TIN$ for tin descriptions, STK$ for
grid stacks, IMG$ for images, and LAT$ for lattice descriptions.
Projection information about the geo_dataset is stored in PRJ$
reserved variables with the exception if images.

•	The ARC commands DESCRIBE, DESCRIBETIN, and
DESCRIBELATTICE also set the DSC$, GRD$, TIN$, and LAT$
reserved variables, respectively.

•	The reserved AML variables created by describing a grid or
lattice are:

Reserved GRD$ Variable

Description

GRID

grid name or lattice name

FULL_GRID

full grid name or full lattice name

DX

cellsize in X dimension; distance in X between mesh points

DY

cellsize in Y dimension; distance in Y between mesh points

XMIN

minimum X coordinate

YMIN

minimum Y coordinate

XMAX

maximum X coordinate

YMAX

maximum Y coordinate

ZMIN

minimum of VALUE in grid

ZMAX

maximum of VALUE in grid

MEAN

mean of value in grid (-9999 if unknown)

STDV

standard deviation of VALUE (-9999 if unknown)

NCOLS

number of columns; number of mesh points in X dimension

NROWS

number of rows; number of mesh points in Y dimension

NCLASS

number of classes (for integer grids only) (0=floating point)

TYPE

the grid type (1 for integer and 2 for floating point)

ฉ 1995 A.C.T. GIS, Inc.

Page 177

-------
GRID Training Course

AML Functions

September 16. 1995

User Input Functions - GETGRID

•	Displays a menu of grids from which one can be selected

•	Usage: [GETGRID { {prompt_string}}

{-SORT I -NOSORT} {-NONE} {-OTHER}]

Arguments

•	 I  is used to identify the set of grids to
list

•	{prompt_string} allows a prompt to be given

•	-SORT is used to sort the list of choices

•	-NOSORT is used to turn off sorting of the list of choices

•	-NONE means NONE will be provided as a valid selection

•	-OTHER means _OTHER_ is choice and when selected, terminal
input is requested

Returned Type

•	string
Returned Value

•	The full pathname to the selected grid, or a null string if no
choice was selected

ฉ 1995 A.C.T. GIS, Inc.

Page 178

-------
GRID Training Course

AML Functions

September 16. 1995

User Input Functions - GETGRID (Continued)

Notes

•	&terminal must be set prior to using this function

•	On X-windows devices, the choices are displayed as a scrolling
list in a popup window

•	If none is selected, a null string is returned.

•	The -NOEXTENSION option does not suppress file extensions
in the returned string

•	Since the comment string in AML is /* and UNIX pathnames use
the forward slash, pathnames ending with a wildcard character
should be quoted.

•	If the wild card is omitted, all grids in the current workspace
will be listed

Example:

Arc: &s grid := [getgrid * 'Select a Grid' -sort]

ฉ 1995 A.C.T. GIS, Inc.

Page 179

-------
GRID Training Course	 September 16. 1995

AML Functions

User Input Functions - GETIMAGE

•	Displays a menu of images from which one can be selected

•	Usage: [GETIMAGE { {<-image_type}
{prompt.string}} {-SORT I -NOSORT} {-NONE} {-OTHER}}!

Arguments

•	 I  is used to identify the set of grids to
list

•	<-image_type> indicates the image type to display. Valid
choices are:

-EXT, -ALL, -ADRG, -BIL, -BIP, -BSQ, -ERDAS, -GRID, -
IMAGINE, -RLC, -SUNRASTER, and -TIFF

•	{prompt_string} allows a prompt to be given

•	-SORT is used to sort the list of choices

•	-NOSORT is used to turn off sorting of the list of choices

•	-NONE means NONE will be provided as a valid selection

•	-OTHER means _OTHER_ is choice and when selected, terminal
input is requested

Returned Type

•	string
Returned Value

•	The full pathname to the selected image, or a null string if no
choice was selected

ฉ 1995 A.C.T. GIS, Inc.

Page 180

-------
GRID Training Course

AML Functions

September 16. 1995

User Input Functions - GETIMAGE (Continued)

Notes

•	&terminal must be set prior to using this function

•	On X-windows devices, the choices are displayed as a scrolling
list in a popup window

•	If none is selected, a null string is returned.

•	-EXT is the default and returns only those image files with valid
file extensions.

Example:

Arc: &s image := [getimage * -tiff 'Select an Image' -sort]

ฉ 1995 A.C.T. GIS, Inc.

Page 181

-------
GRID Training Course			—	September 16. 1995

AML Functions

User Input Functions - GETSTACK

•	Displays a menu of grid stacks from which a selection can be
made

•	Usage: [GETSTACK { I wild_card>

{prompt_string}} {-SORT I -NOSORT} {-NONE} {-OTHER}]

Arguments

•	 I  is used to identify the grid stacks to
list

•	{prompt_string} allows a prompt to be given

•	-SORT is used to sort the list of choices

•	-NOSORT is used to turn off sorting of the list of choices

•	-NONE means NONE will be provided as a valid selection

•	-OTHER means _OTHER_ is choice and when selected, terminal
input is requested

Returned Type

•	string
Returned Value

•	The full pathname of the selected grid stack, or a null string is
no selection was made

Notes

•	^terminal must be set prior to using this function

•	On X-windows devices, the choices are displayed as a scrolling
list in a popup window

ฉ 1995 A.C.T. GIS, Inc.

Page 182

-------
GRID Training Course

AML Functions

September 16.1995

User Input Functions - GETSTACK (Continued)

•	If none is selected, a null string is returned.

•	If the wild card is omitted, the tins in the current workspace are
listed

•	Since the comment string in AML is /* and UNIX pathnames use
the forward slash, pathnames ending with a wildcard character
should be quoted.

Example:

Arc: &s stack := [getstack * 'Select a grid stack' -sort]

ฉ 1995 A.C.T. GIS, Inc.

Page 183

-------
A BCDEFG H I J K L 171 NOPQRSTUVWXYZ

A B C D

E F G H I J K L f;1 N 0 P Q R S TU V W X Y Z

An alphabetical list of GRID commands

A

ABBREVIATIONS
ADDTOSTACK
AP

ARCTOOLS
ATUSAGE

B

BUILDSTA
BUILDVAT

c

CELLVALUE
CLASSSAMPLE

COMMANDS
CONVERTREMAP
COPY
COPYSTACK

turns command abbreviations on or off.

adds one or more grids to a stack.

allows entry of ARCPLOT commands directly

from the Grid: prompt.

invokes the ARC/INFO menu interface.

returns the usage for ATOOL commands.

builds a statistics file (STA) for a grid based upon
the VALUE item.

builds a value attribute table (VAT) for a grid.

returns the value and attributes for the cell
containing a specified point,
enables to interactively select training samples on
the displayed composite of stack's layers, helps to
evaluate taken samples, and saves them in a grid,
lists available GRID commands or just those
commands which begin with (prefix),
converts remap tables from INFO to ASCII files or
ASCII to INFO files.

duplicates a grid. All information associated with
the grid is duplicated.

copies a stack including its component grids to a
new stack.

CORRELATION

CREATEREMAP

D

DENDROGRAM

DESCRIBE
DRAWSIG
DRAWZONESHAPE
DROPFROMSTACK

E

EXTERNAL
EXTERNALALL

F

FILL
FORMEDIT

An alphabelical list of GRID commands

calculates the cross correlation between two input
grids and prints the correlation coefficient to the
screen.

generates a remap table for a grid.

constructs a tree diagram showing the distances
between sequentially merged classes in a
signature file.

provides a detailed description of a grid and its
contents.

displays class signatures as ellipses in a two
dimensional graph.

draws ellipses approximating the shape and

orientation of each zone.

eliminates one or more grids from a stack.

corrects external .file pathnames for a geographic
data set's INFO data files,
recursively finds all subdirectories under the
specified directory and corrects the external file
pathnames of the INFO data .files for all
geographic data sets found in all workspaces

fills sinks or levels peaks in a continuous grid to
remove small imperfections in the data,
starts the graphical form editor for AML form

=•• Master ;v::: .Index-.:/..Local	First v'.' Previous %'ฆ' Next Print J'-"; Viewer	Master! V ; Index i Local: v;! Go First v-: Previous. ;• .Nexti Prini.: :Vioivor Quit

.Contoints.;:--:;-::;->:/-.:::/.Content6';::;Back	; He!p:;Contents •:.-::i.V:A:;::/.;Contents<:'.: Back^•^•;•^Pagels::•.::i;\PagBฆ:;;^';;P3ge; ^ riiv::-.-.; j--'J Help

B C D E.F G H I J K L M NO P Q R S TU V W XY Z	A B CDE F G H I J KL UN OP QRSTUVWXYZ

G

GEARY

GRIDCOMPOSITE
GRIDEDIT
GRIDNODATA-
SYMBOL
GRIDPAINT

GRIDQUERY

GRIDSHADES

H

HELP
HISTOGRAM

IMAGE
INDEXITEM
INFO

K

KILL

An alphabetical list of GRID commands

calculates the Geary spatial autocorrelation index
for a grid and prints it to the screen,
displays three grids as a composite image,
the grid editing command prefix,
sets the shade symbol or colormap index for
displaying grid cells with NODATA.
displays a grid using the specified item value,
stretch or remap_table and a colormap_file.
displays the set of cells in a grid that satisfy a
logical expression using the current shadeset.
shades a grid using the specified item value,
stretch, or remap table to determine color from
the current shadeset.

starts ArcDoc, the on-line documentation system
for ARC/INFO.

displays the frequency distribution of values in a
grid.

displays a raster image or a group of images from
an image catalog.

creates an attribute index to increase access speed
to the specified item during query operations
begins execution of the INFO subsystem for ARC
using the INFO subdirectory in the current user
workspace.

deletes a grid or stack.

L

LIST

LISTCOVERAGES
LISTGRIDS
LISTIMAGES
LISTSTACKS
LLSFIT

LOADCOLORMAP
LOG

M

MAKESTACK
MERGEVAT

MORAN

P

PRINT
PRINTDOC
PROJECT-
COMPARE

Q

QUIT

An alphabetical list of GRID commands

lists the item values for all records of the specified
INFO data file.

lists the coverages contained in a workspace,
lists the grids contained in a workspace,
lists the images contained in a directory,
list the stacks contained in a workspace,
performs a linear least-squares fit to a link file or
link coverage and reports the RMS error and
coefficients.

loads the colors of an ASCII colormap file into the
current shadeset.

lists the contents of a log file or add a new entry to
the log.

generates a stack from a given set of grids,
merges the value attribute tables, VATs, of two
grids.

calculates the Moran spatial autocorrelation
index for a grid and prints it to the screen.

prints the results of an expression to the screen,
invokes a menu for printing multiple ArcDoc files
sets the comparison level of the present session

stops execution of the GRID system and returns
control to the ARC system

j-VMaster Index-.' Local • • Go.. :- FirstiPrcvious Next Print : Vl*r/er ; ;;Ouit
I'Conients	Contents ~ Back \*V"Page;-::''^Fagฎ Page	Help1''.

Master ^index;!;-.^-Local •'' Qo . ;FJrsi Previous Next .Prim viewer • ioult.
Contents' ^. Contents;-Back ! Page^ .^Page.- ; Page-. . • Hetp

-------
ABC DEF G H I J KLMNO P O R STUVWXYZ	A B CD E F G H I J K L MNOPQ R S TU V W XY 2

An alphabetical list of GRID commands

R

REGRESSION outputs the regression coefficients for the
regression model in tabular form.

REMAPGRID a menu-based tool for creating custom remap
tables for a grid.

REMOVESCALAR removes or deletes a scalar variable.

RENAME changes the name of a grid.

RESET re-initializes the GRID analysis environment to
the default settings.

RESTORE restores the GRID analysis environment to the
settings stored in an environment file.

s

SAI creates an output grid containing a slope-aspect
index, or a lookup table of hypothetical solar
illumination to be used for displaying.

SAVE saves the current GRID analysis environment.

SAVECOLORMAP saves the colors corresponding to symbols in the
current shadeset to an ASCII colormap file.

SCATTERGRAM displays a graph showing in a two dimensional
space the distribution of one grid's cells' values
against another grid.

SETCELL sets the cell size of the current analysis
environment.

SETMASK sets the mask of the current analysis
environment.

SETWINDOW seta the window of the current analysis
environment.

SHADEGRID a menu-based tool for generating shade sets and
remap tables that can be used to create a custom
display of a grid.

An alphabetical list of GRID commands

SHOW lists the current setting of the User workspace,
display device, method of coordinate input, or
digitizer on your terminal screen.

STACKHISTOGRAM displays a set of histograms, ones for each layer
a stack.

displays a set of graphs, one for each pair of a
stack's layers, showing in a two dimensional
space the distribution of cell values,
displays all layers of a stack in a layout fashion
using the current shade set.
calculates the statistics for layers of a stack,
shows the status of the current GRID analysis
environment.

STACKSCATTER-
GRAM

STACKSHADE

STACKSTATS
STATUS

u

USAGE

V

VERIFY
VISDECODE

VISENCODE

returns the usage of the specified command.

sets the automatic verification of answers to
system prompts.

returns a list of observation points that can be
seen by cell locations with a specified value in the
VALUE item of the output grid from the
VISIBILITY function.

returns the VISIBLE-CODE value or values that
are assigned to each cell location on the output
grid created by the VISIBILITY function which
can be seen by up to sixteen specified points.

. Master -.
Contents..

;Index':-i'/'-i local'-^V'.Go First)':';.'.'/Previous NextPrim.-•Viewer	;

v:^:o^Contflms'v.!'. Back-''.'.:1':J Page .V ;j.:.Ppgซ •/• \.'.Pagd

Master .:; - Index
Contents

• V Local • Go •First ^-Previous ; Next • .v Print ;.'^VlewerV--;:iQuil
' Contents -'Back Page';.;.'.';"- Page..Page -:

-------
A BCD E F G H IJKLM NOPQRSTUVWXYZ

ABCDEFGH I J K L M N OPQRSTUV W X Y Z

alphabetical list of GRID functions

ABS
ACOS
ACOSH

ADJUST

AGGREGATE

ASIN
ASINH
ASPECT

ATAN
ATAN2

ATANH

B

BASIN
BLOCKMAJORITY

calculates the absolute value of the input,
calculates the inverse cosine of the input,
calculates the inverse hyperbolic cosine of the
input.

adjusts or rubber sheets a grid in either direction
along the links from a separate link coverage,
generates a reduced resolution version of a grid
where each output cell contains the MIN, MAX,
MEAN, MEDIAN, or SUM of the input cells that
are encompassed by the extent of the output cell,
calculates the inverse sine of the input,
calculates the inverse hyperbolic sine of the input,
identifies the direction of maximum rate of change
in z value from each cell,
calculates the inverse tangent of the input,
calculates the inverse tangent (based on y/x) of
the input.

calculates the inverse hyperbolic tangent of the
input.

creates a grid delineating all drainage basins
within the analysis window,
an aggregation function that partitions the input
grid into blocks and finds the majority of the
values for the specified cells (defined by the
neighborhood parameters) within the block and

An alphabetical list of GRID functions

sends it to each cell location in the block on the
output grid.	-

BLOCKMAX an aggregation function that partitions the input
grid into blocks and finds the highest value for the
specified cells (defined by the neighborhood
parameters) within the block and sends it to each
cell location in the block on the output grid.

BLOCKMEAN an aggregation function that partitions the input
grid into blocks land finds the mean value for the
specified cells (defined by the neighborhood
parameters) within the block and sends it to each
cell location in the block on the output grid.

BLOCKMEDIAN an aggregation function that partitions the input
grid into blocks and finds the median value for the
specified cells (defined by the neighborhood
parameters) within the block and sends it to each
cell location in the block on the output grid.

BLOCKMIN an aggregation function that partitions the input
grid into blocks and finds the smallest value for
the specified cells (defined by the neighborhood
parameters) within the block and sends it to each
cell location in the block on the output grid.

BLOCKRANGE an aggregation function that partitions the input
grid into blocks and finds them range of values for
the specified cells (defined by the neighborhood
parameters) within the block and sends it to each
cell location in the block on the output grid.

BLOCKSTD an aggregation function that partitions the input
grid into blocks and finds the standard deviation
of values for the specified cells (defined by the
neighborhood parameters) within the block and
sends it to each cell location in the block on the
output grid.

B C D E F G HI J KL MNOPQRSTUVW X Y Z

A BCOtF G H I J K L M N O P Q R S T U V W X Y Z

BLOCKSUM

BLOCKVARIETY

BOUNDARYCLEAN

c

CEIL
CLASSPROB
CLASSSIG

COLOR2BLUE

COLOR2GREEN

COLOR2HUE

An alphabetical list of GRID functions

an aggregation function that partitions the input
grid into blocks and finds the sum of values for the
specified cells (defined by the neighborhood
parameters) within the block and sends it to each
cell location in the block on the output grid,
an aggregation function that partitions the input
grid into blocks and finds the variety of the values
(the number of different values) for the specified
cells (defined by the neighborhood parameters)
within the block and sends it to each cell location
in the block on the output grid,
smooths the boundary between zones by
expanding and shrinking the boundary.

returns the next highest whole value that is

greater than or equal to the input values.

creates a stack of probability layers for each class

represented in the signature file.

creates an ASCII signature file that contains

signatures of classes, defined as class samples in

the input grid, in the input stack

converts a grid and associated colormap into a

grid representing the RGB blue components of the

input.

converts a grid and associated colormap into a
grid representing the RGB green components of
the input.

converts a grid and associated colormap into a
grid representing the HSV hue components of the
input.

COLOR2RED

COLOR2SAT

COLOR2VAL

COMBINE

CON
CORRIDOR

COS
COSH

COSTALLOCATION

COSTBACKLINK

COSTDISTANCE

COSTPATH

An alphabetical list of GRID functions

converts a grid and associated colormap into a
grid representing the RGB red components of the
input.

converts a grid and associated colormap into a
grid representing the HSV saturation components
of the input.

converts a grid and associated colormap into a
grid representing the HSV value components of
the input.

combines multiple grids on a cell-by-cell basis,
such that a unique output value is assigned to
each unique combination of input values,
performs one or more conditional ltfelse
evaluations.

records for each cell location the sum of tne
accumulative costs for two input accumulative-
cost grids.

calculates the cosine of the input,
calculates the hyperbolic cosine of the input,
identifies for each cell the zone of each source cell
that could be reached with the least accumulative
cost.

defines the neighbor that is the next cell on the
least-accumulative-cost path from a cell to a set of
source cells.

calculates for each cell the least-accumulative-
cost distance over a cost surface to a source cell or
a set of source cells.

produces an output grid that records the least-cost
path(s) from selected cell(s) in the input
, or from interactive selection on
the display, to the closest source cell defined

: Ma$tcr	. :	. . Co • Fir*t ;v' Previous :	print : . Viซwer. Quit

Contents	''Contents" Back : Page?:v":P*ge Page	Help

: Masters, index Local Go : First ฆ Previous Next Print Viewer
Cpntents^ i. Contented BicK^'.SPifle ฆ 'Page . . Page	ฆ":Hซlpฆ-j'"-

-------
A B C D E F G H I J KLMNOPO RSTUVWXYZ

ABCDEFGH IJ K L M N O PQRSTUVWXYZ

CURVATURE

D

DARCYFLOW

E

EDITSIG
EQUALTO

EUCALLOCATION
EUCDIRECTION

EUCDISTANCE

EXP
EXP 10
EXP2
EXPAND

An alphabetical list of GRID functions

within the  in terms of cost
distance.

calculates the curvature of a surface at each cell
center.

calculates the groundwater volume balance
residual for steady state flow in an aquifer and
the seepage velocity for each cell using Darcy*s
Law.

edits a signature file by merging, renumbering
and deleting class signatures and creates a new
signature file.

evaluates, on a cell-by-cell basis, the number of
times in an argument list that the input grid
values are equal to the value specified by the first
argument.

calculates for each cell the zone of the closest
source cell (in Euclidean distance),
calculates the direction in degrees that each cell
center is from the cell center of the closest source.
The output values are based on compass
directions, with 0" being reserved for the source
cells.

calculates for each cell the Euclidean distance to
the closest source.

calculates the basee exponential of the input,
calculates the baselO exponential of the input,
calculates the base2 exponential of the input,
expands the selected zones by a specified number
of cells.

F

FLIP
FLOAT
FLOOR

FLOWACCUM-
ULATION

FLOWDIRECTION

FLOWLENGTH

FMOD

FOCALFLOW
FOCALMAJORITY

FOCALMAX

FOCALMEAN

FOCALMEDIAN

An alphabetical list of GRID functions

flips a grid along a horizontal axis.

converts integer values to floating-point values.

returns the greatest integer value that is smaller

than or equal to the input values.

creates a grid of accumulated flow to each cell,

by accumulating the weight for fill cells that flow

into each downslope cell.

creates a grid of flow direction from each cell to its
steepest downslope neighbor,
calculates distance, or weighted distance along a
flow path.

divides the values of the first input by the second
input and returns the remainder on a cell-by-cell
basis.

determines the flow of the values in the input grid
within each cell's immediate neighborhood,
for each cell location on an input grid, finds the
'majority* value (the value that appears most
often) within a specified neighborhood and sends
it to the corresponding cell location on the output
grid.

for each cell location on an input grid, finds the
highest value within a specified neighborhood and
sends it to the corresponding cell location on the
output grid.

for each cell location on an input grid, finds the
mean of the values within a specified
neighborhood and sends it to the corresponding
cell location on the output grid,
for each cell location on an input grid, finds the
median value within a specified neighborhood and

ABCDEFGH I J KLMNOP QRSTUVWXYZ

An alphabetical list of GRID functions

sends it to the corresponding cell location on the
output grid.

for each cell location on an input grid, finds the
minimum value within a specified neighborhood,
and sends it to the corresponding cell location on
the output grid.

for each cell location on an input grid, finds the
range of the values within a specified
neighborhood and sends it to the corresponding
cell location on the output grid,
for each cell location on an input grid, finds the
standard deviation of the values within a specified
neighborhood and sends it to the corresponding
cell location on the output grid,
for each cell location on an input grid, adds the
values within a specified neighborhood and sends
the sum to the corresponding cell location on the
output grid.

for each cell location on an input grid, determines
the number of unique values (or the variety)
within a specified neighborhood and sends it to
the corresponding cell location on the output grid.

FOCALMIN

FOCALRANGE

FOCALSTD

FOCALSUM

FOCALVARIETY

G

GREATERTHAN

GRIDLINE
GRSDPOINT
GRIDPOLY

evaluates, on a cell-by-cell basis, the number of
times in an argument list that the input grid
values are greater than the value specified by the
first argument.

converts a grid representing rasterized linear
features to a line coverage.

converts a grid representing raster point features

into a point coverage.

converts a grid to a polygon coverage.

H

HILLSHADE
HSV2BLUE
HSV2GREEN
HSV2RED

IDW
INT
ISNULL
ISOCLUSTER

K

KRIGING

An alphabetical list of GRID functions

creates a shaded relief grid from a grid by
considering the sun illumination angle and
shadows.

converts three grids representing the hue,
saturation, and value of an HSV color model to a
blue grid for an RGB color model,
converts three grids representing the hue,
saturation, and value of an HSV color model to a
green grid for an RGB color model,
converts three grids representing the hue,
saturation, and value of an HSV color model to a
red grid for an RGB color model

performs an inverse distance weighted

interpolation on a point data set.

converts input floating-point values to integer

values through truncation.

returns '1' if the input value is NODATA, and '0' if

it is not.

uses an isodata clustering algorithm to determine
the characteristics of the natural groupings of
cells in a multi-dimensional space, and stores the
results in an ASCII signature file.

interpolates a point data set into a surface using
knging.

Print Viewer ouit
Contents •. vv'-'v ^Contents • - Back ฆ•••• Page Psgc Page •:	-Help

Master index LOcaiV^.V-Goxi'^ First Previous Next Print Viewer:: ..QuH-
Contents	ContentsBack . ,. Page' P*ge Page' ฆ' ฆ ฆ

-------
ABC 0 E F G HI J KIM NO P 0 R S TU V W X Y Z

ABCDEFGH IJ KLM NO P Q R S TU V W X Y Z

An alphabetical list of GRID functions

L

LESSTHAN evaluates, on a cell-by-cell basis, the number of
times in an argument list that the input grid
values are less than the value specified by the first
argument.

LINEGRID creates a grid from line features in a coverage.

LN calculates the natural logarithm (basee) of the
input.

LOGIO calculates the base 10 logarithm of the input.

LOG2 calculates the base2 logarithm of the input.

. LPOS determines, on a cell-by-oell basis, the position of
the input grid with the minimum value in the
argument list.

M

MAJORITY uses multiple input grids to determine the

'majority* value (the value that appears most
often) on a cell-by-cell basis.

MAJORITYFILTER replaces cells in a grid based upon the majority of
their contiguous neighboring cells.

MAX uses multiple input grids to determine the
maximum value on a cell-by-cell basis.

MEAN uses multiple input grids to determine the mean
value on a cell-by-cell basis.

MED uses multiple input grids to determine the median
value on a cell-by-cell basis.

MERGE merges multiple, possibly nonadjacent input grids
into a single grid based upon order of input.

MIN uses multiple input grids to determine the
minimum value on a cell-by-cell basis.

MINORITY uses multiple input grids to determine the

'minority' value (the value that appears least
often) on a cell-by-cell basis.

Master	/.First "^Previous'-Ivi'Next :;v:- Print;..'Viev/er i;:;.VQult:;:

Coซttonis//^:^i::ฃ;ฃContent^

B C D E F G H I J KLM NOPQRSTUVW X Y 2

MIRROR
MLCLASSIFY

MOSAIC

N

NIBBLE
NORMAL

PARTICLETRACK
PATHDISTANCE

PICK

POINTGRID
POLYGRID
POPULARITY

POROUSPUFF

An alphabetical list of GRID (unctions

mirrors a grid along a vertical axis,
performs maximum likelihood classification on a
stack and creates the classification grid,
creates one grid out of many adjacent grids and
makes a smooth transition over the overlapping
areas of the neighboring grids

replaces areas in a grid corresponding to a mask,
with the values of the nearest neighbors,
creates a grid with randomly dispersed values of a
normal distribution.

calculates the path of a particle through a velocity
field.

calculates, for each cell, the least-accumulative-
cost distance over a cost surface from a source cell
or a set of source cells while accounting for surface
distance and horizontal and vertical cost factors,
using the values of an input grid, determines
which expression will be used, and uses it to
compute the output values,
creates a grid from points in a coverage,
creates a grid from polygons in a coverage,
determines the value in an argument list that is
at a certain level of popularity on a cell-by-cell
basis within the analysis window. The particular
level of popularity (the number of occurrences of
each value) is specified by the first argument,
calculates the time-dependent, two-dimensional
concentration distribution of a solute, introduced

10

ASCO EF GH I J K L M N 0 P Q R S TU V W X Y Z

POW
PRINCOMP

PROJECT

R

RAND
RANK

RECLA.SS
REGIONGROUP

RESAMPLE
RGB2HUE

RGB2SAT
RGB2VAL
ROTATE

An alphabetical list of GRID functions

instantaneously at a discrete point into a

vertically mixed aquifer.

calculates the nth power of the input.

generates a stack of layers being the principal

components of the input stack

projects coordinates between two projections for a

grid.

generates a random number between '0' and '1'.
returns the value in the th position in the
rank order of the argument list, which is created
using the specified multiple input grids, on a cell-
by-cell basis.

reclassifies (or changes) the value of the input
cells using a remap table on a cell-by-cell basis,
records for each cell in the output the identity of
the connected region to which it belongs A unique
number is assigned to each region
changes the cell size of a grid,
converts three grids representing the red, green,
and blue of an RGB color model to a hue grid for
an HSV color model.

converts three grids representing the red, green,
and blue of an RGB color model to a saturation
grid for an HSV color model,
converts three grids representing the red, green,
and blue of an RGB color model to a value grid for
an HSV color model.

rotates a grid around the lower left corner by a
specified angle.

s

SAMPLE
SAMPLESIG

SCALAR

SELECT

SELECTBOX
SELECTCIRCLE
SELECTMASK

SELECTPOINT

SELECTPOLYGON
SETNULL

SHIFT

SHRINK

SIN
SINH

An alphabetical list of GRID functions

lists the values of a group of cells from one or
more grids.

creates an ASCII signature file that contains a set
of statistics defining zones specified in the input
file.

returns the result of a map algebra expression

involving numbers as a numeric value that can be

assigned to a scalar variable.

based on the evaluation of the

, selects cell values from the

input grid on a cell-by-cell basis.

selects cells from the input grid that are either

inside or outside a specified box.

selects cells from the input grid that are either

inside or outside a specified circle.

masks (or sets to NODATA) all cell locations in

the first input grid that have been assigned

NODATA in the second input grid.

selects cells from the input grid that are either

inside or outside the boundary of the cell within

which a selected point falls.

selects cells from the input grid that are either

inside or outside a polygon

returns NODATA if the evaluation of the input

condition is TRUE', if it 'FALSE', returns the

value specified by the second input argument.

shifts the coordinates of a grid, and optionally

changes the cell size.

shrinks the selected zones by a specified number
of cells.

calculates the sine of the input,
calculates the hyperbolic sine of the input.

• Master.Index •• Local -Go First Previous . Next = . •••• Print r: Vlewซr,..:.;.,OuU.>;
Contents'-- Contents Bac^-urPage^NPage v.Page v.-.- . >Heip _ %

ฆMaster	LocalGo/•:ฅi'r-Fซrsi';>':'-Pปevlous Ne*t Print ViliwerV'.ฆฆฆ''Quir

contentsv ; s\ contents : Back Page . Page Page	Heipjy ; v t

-------
ABCDEF6 H I J K L MN0P0:RSTUVWXY2

A B CDEFGH I J K L M N 0 P Q R S T.U V W X Y Z

SINK
SLICE

SLOPE
SNAPPOUR

SPLINE

SQR
SQRT
STREAMLINE

STREAMUNK

STREAMOROER

T

TAN
TANH
TEST

THIN

TREND

An alphabetical list of GRID functions

creates a grid identifying all sinks, or areas of
internal drainage.

'slices' (or changes) a range of values of the input
cells by specified ranges, zones of equal area, or
zones with equal intervals',
identifies the rate of maximum change in z value
from each cell.

snaps selected pour points to the cell of highest
flow accumulation within a specified
neighborhood.

performs a spline interpolation on a point data set

resulting in a smoothed surface with the

minimum curvature.

calculates the square of the input.

calculates the square root of the input.

converts a grid representing a raster linear

network to a line coverage.

assigns unique values to sections of a raster linear

network between intersections.

assigns a numeric order to segments of a grid

representing branches of a linear network.

calculates the tangent of the input,
calculates the hyperbolic tangent of the input,
uses a Boolean evaluation of the
 to test the cell values from
the input grid and to set the output to '1' or *0' on a
cell-by-cell basis.

thins raster linear features by reducing the
number of pixels representing the width of the
features.

performs a trend interpolation on a point data set.

u

UPOS

V

VARIETY
VISIBILITY

w

WARP
WATERSHED

ZONALAREA
ZONALCENTROID

ZONALFILL

ZONALGEOMETRY

ZONALMAJORITY

An alphabetical list of GRID functions

determines, on a cell-by-cell basis, the position of,
the input grid with the maximum value in the
argument list.

uses multiple input grids to determine the variety
of the values (the number of unique values) on a
cell-by-cell basis.

performs visibility analysis on a grid by
determining how many observation points can be
seen from each cell location of the input grid, or
which cell locations can be seen by each
observation point.

rubber sheets a grid along a set of links using a
polynomial transformation,
determines the contributing area above a set of
cells in a grid.

calculates the area of each zone in the input grid,
creates a grid with cells locating the geometric
centers of each zone of an input grid,
fills zones using the minimum cell value from a
weight grid, along the zone boundary,
calculates for each zone of the input grid its area,
perimeter, thickness, and the characteristics of
ellipse and records them in the output INFO file
records in each output cell the majority value (the
value that appears most often) of all cells in the

13

14

A B C D E F G H I J K L M N O P Q R S TU V W X Y Z

An alphabetical list of GRID functions

 that belongs to the same zone as the
output cell. Zones are identified by the values of
the cells in the input .
records in each output cell the maximum value of
all cells in the  that belong to the
same zone as the output cell. Zones are identified
by the values of the cells in the input .
records in each output cell the mean of the values
of all cells in the  that belong to the
same zone as the output cell. Zones are identified
by the values of the cells in the input 
records in each output cell the median value of all
cells in the  that belongs to the same
zone as the output cell. Zones are identified by the
values of the cells in the input .
records in each output cell the minimum value of
all cells in the  that belong to the
same zone as the output cell. Zones are identified
by the values of the cells in the input .
calculates the perimeter of each zone in the input
grid.

records in each output cell the range of values of
all cells in the  that belong to the
same zone as the output cell. Zones are identified
by the values of the cells in the input 
records in an output INFO table the minimum,
maximum, range, sum, mean, standard deviation
and variety of the values of all cells in the
 that belong to the same zone. Zones
are identified by the values of the cells in the
input .

records in each output cell the standard deviation
of the values of all cells in the  that

ZONALMAX

ZONALMEAN

ZONALMEDIAN

ZONALMIN

ZONALPERIMETER
ZONALRANGE

ZONALSTATS
ZONALSTD

A BCOEFG H I J K L M N 0 P Q RSTUVWXY Z

An alphabetical list of GRID functions

belong to the same zone as the output cell. Zones
are identified by the values of the cells in the
input .

records in each output cell the sum of the values
of all cells in the  that belong to the
same zone as the output cell. Zones are identified
by the values of the cells in the input .
calculates for each zone on an input grid the
deepest or thickest point within the zone from its
surrounding cells.

records in each output cell the variety of values
(the number of unique values) of all cells in the
 that belong to the same zone as the
output cell. Zones are identified by the values of
the cells in the input .

ZONALSUM

ZONALTHICKNESS

ZONALVARIETY

•. Master Index LOMl : v Co Fir$t . . .Previous :	Print;ViewersQuit

ฆ Contents . ; Contents Back ...Page . Pag* Page .	Help

'Master. indox Local. Go , Rrsi Previous -'.Next Prim ''Viewer' Quit..
Contents ..^Contents • -Back 'I.Page . Page' '; ..Page	Help	rv

-------
An alphabetical list of GRID operators

alphabetical list of GRID operators

I performs a Boolean-exclusive-OR operation on
two inputs.

!! performs a bitwise-exclusive-OR operation on the

binary values of two inputs.

& performs a Boolean-AND operation on two inputs.
&& performs a bitwise-AND operation on the binary
values of two inputs.

* multiplies the values of two inputs.
*= multiplies the values of a grid on a cell-by-cell
basis within a DOCELL block and assigns the
results to a scalar variable.

+ adds the values of two inputs.

+= adds the values of a grid on a cell-by-cell basis
within a DOCELL block and assigns the results to
a scalar variable.

subtracts the values of the second input from the
values of the first input.

-= subtracts the values of a grid on a cell-by-cell
basis within a DOCELL block and assigns the
results to a scalar variable.

/= divides the values of a grid on a cell-by-cell basis
within a DOCELL block and assigns the results to
a scalar variable.

:= creates a temporary output grid from an

expression within a DOCELL block.

< performs a relational-less-than operation on two
inputs.

ซ performs a bitwise-left-shift operation on the
binary value of an input.

<= performs a relational-less-than-or-equal-to
operation on two inputs.

= creates a new output grid from an input
expression.

== performs a relational-equal-to operation on two
inputs.

> performs a relational-greater-than operation on
two inputs.

ป performs a bitwise-right-shift operation on the
binary value of an input.

>= performs a relational-greater-than-or-equal-to
operation on two inputs.

CAND performs a combinatorial-AND operation on two
input grids.

COR performs a combinatorial-OR operation on two
input grids.

CXOR performs a combinatorial-exclusive-OR operation
on two input grids.

DIFF determines which values from the first input are
logically different from the values of the second
input.

DIV divides the values of two inputs.

IN determines which values from the first input are
contained in the .

MOD divides the values of the first input by the values
of the second input and returns the remainder.

OVER returns those values from the first input that are
nonzero; otherwise, returns the value from the
second input.

UNARY- changes the sign of the input (multiplies by -1).

A performs a Boolean-complement operation on an
input.

An alphabetical list of GRID operators

** performs a bitwise-complement operation on the
binary value of an input.

*= performs a relational-not-equal-to operation on
two inputs.

{= determines the minimum value of a grid within a
DOCELL block and assigns the result to a scalar
variable.

I	performs a Boolean-OR operation on two inputs.

II	performs a bitwise-OR operation on the binary
values of two inputs.

}= determines the maximum value of a grid within a
DOCELL block and assigns the result to a scalar
variable.

-------
An alphabetical list of GRID statements

DOCELL controls per-cell processing on a cell-by-cell basis.

IF performs a conditional iffelse evaluation on a cell-
by-cell basis.

WHILE repeats a statement list body as long as the tested
condition is a semi-Boolean TRUE value
(nonzero).

1

I VMaster%

;: t n d 6 *=; f'=: •. L'o ca t;: ;•

:
-------
A functional list of GRID commands

.A functional list of GRID commands

Accumulative operators
Arithmetic operators
Assignment operators
Bitwise operators
Block (unctions
Boolean operators
Color model conversion
Combinatorial lunctions
Combinatorial operators
Conditional statements
Data cleanup functions
Data conversion
Distance functions
Editing commands

Exponential and logarithmic functions
Focal functions
Geometric transformation
Grid display

GRID management commands
Hydrologic functions
Logical operators
Miscellaneous functions
Reclassification functions
Relational operators

Selection functions
Shape analysis functions
Statistical functions and commands
Surface functions and commands
Trigonometric functions
Visibility tools
Zonal functions

(MORE)

A functional list of GRID commands

A functional list of GRID commands

Arithmetic operators

multiplies the values of two inputs.

+ adds the values of two inputs.

subtracts the values of the second input from the
values of the first input.

DIV divides the values of two inputs.

MOD divides the values of the first input by the values
of the second input and returns the remainder.
UNARY - changes the sign of the input (multiplies by -1).

Boolean operators

! performs a Boolean-exclusive-OR operation on
two inputs.

& performs a Boolean-AND operation on two inputs.
A performs a Boolean-complement operation on an
input.

I performs a Boolean-OR operation on two inputs.

Relational operators

< performs a relational-less-than operation on two
inputs.

<= performs a relational-less-than-or-equal-to

operation on two inputs.

== performs a relational-equal-to operation on two
inputs.

> performs a relational-greater-than operation on
two inputs.

>= performs a relational-greater-than-or-equal-to

operation on two inputs.

*= performs a relational-not-equal-to operation on
two inputs.

Bitwise operators

'! performs a bitwise-exclusive-OR operation on the
binary values of two inputs.

&& performs a bitwise-AND operation on the binary

values of two inputs.

ซ performs a bitwise-left-shift operation on the

binary value of an input.

ป performs a bitwise-right-shift operation on the

binary value of an input.

^ performs a bitwise-complement operation on the
binary value of an input.

II performs a bitwise-OR operation on the binary
values of two inputs.

Combinatorial operators

CAND performs a combmatonal-AND operation on two
input grids.

COR performs a combinatonal-OR operation on two
input grids.

CXOR performs a combinatonal-exclusive-OR operation
on two input grids.

Logical operators

D1FF determines which values from the first input are
logically different from the values of the second
input.

IN determines which values from the first input are
contained in the .

OVER returns those values from the first input that are
nonzero; otherwise, returns the value from the
second input.

			 Fir$t Prtviogj Next

Contents * Contents A; Back . .- Pagฉ Page . Pag*

Print '^V'- Viewer :Quit
Help . V'

-------
A functional list of GRID commands

A functional list of GRID commands

)=

Accumulative operators

multiplies the values of a grid on a cell-by-cell
basis within a DOCELL block and assigns the
results to a scalar variable,
adds the values of a grid on a cell-by-cell basis
within a DOCELL block and assigns the results to
a scalar variable.

subtracts the values of a grid on a cell-by-cell
basis within a DOCELL block and assigns the
results to a scalar variable,
divides the values of a grid on a cell-by-cell basis
within a DOCELL block and assigns the results to
a scalar variable.

determines the minimum value of a grid within a
DOCELL block and assigns the result to a scalar
variable.

determines the minimum value of a grid within a
DOCELL block and assigns the result to a scalar
variable.

Assignment operators

= creates a new output grid from an input
expression.

:= creates a temporary output grid from an
expression within a DOCELL block.

Trigonometric functions

ACOS calculates the inverse cosine of the input.

ACOSH calculates the inverse hyperbolic cosine of the
input.

AS IN calculates the inverse sine of the input.

ASINH calculates the inverse hyperbolic sine of the input.
ATAN calculates the inverse tangent of the input.

ATAN2

ATANH

COS
COSH
SIN
SINH
TAN
TANH

EXP
EXP10
EXP2
LN

LOG 10
LOG 2
POW
SQR
SORT

calculates the
the input,
calculates the
input.

calculates the
calculates the
calculates the
calculates the
calculates the
calculates the

inverse tangent (based on y/x) of

inverse hyperbolic tangent of the

cosine of the input,
hyperbolic cosine of the input,
sine of the input,
hyperbolic sine of the input,
tangent of the input,
hyperbolic tangent of the input.

AGGREGATE

CONVERTREMAP

CREATEREMAP
RECLASS

Exponential and logarithmic functions

calculates the basee exponential of the input,
calculates the baselO exponential of the input,
calculates the base2 exponential of the input,
calculates the natural logarithm (basee) of the
input.

calculates the baselO logarithm of the input,
calculates the base2 logarithm of the input,
calculates the nth power of the input,
calculates the square of the input,
calculates the square root of the input.

Reclassification functions

generates a reduced resolution version of a grid
where each output cell contains the MIN, MAX,
MEAN, MEDIAN or SUM of the input cells that
are encompassed by the extent of the output cell,
converts remap tables from INFO to ASCII files or
ASCn to INFO files,
generates a remap table for a grid,
reclassifies (or changes) the value of the input
cells using a remap table on a cell-by-cell basis.

A functional list of GRID commands

A functional list of GRID commands

REMAPGRID a menu-based tool for creating custom remap
tables for a grid.

SLICE 'slices' (or changes) a range of values of the input
cells by specified ranges, zones of equal area, or
zones with equal intervals.

Selection functions

SELECT based on the evaluation of the

, selects cell values from the
input grid on a cell-by-cell basis.

SELECTBOX selects cells from the input grid that are either
inside or outside a specified box.

SELECTCIRCLE selects cells from the input grid that are either
inside or outside a specified circle.

SELECTMASK masks (or sets to NODATA) all cell locations in
the first input grid that have been assigned
NODATA in the second input grid.

SELECTPOINT selects cells from the input grid that are either
inside or outside the boundary of the cell within
which a selected point falls.

SELECTPOLYGON selects cells from the input grid that are either
inside or outside a polygon.

TEST uses a Boolean evaluation of the

 to test the cell values from
the input grid and to set the output to '1' or '0' on a
cell-by-cell basis.

Statistical functions and commands

CLASSPROB creates a stack of probability layers for each class
represented in the signature file.

CLASSSAMPLE enables to interactively select training samples on
the displayed composite of stack's layers, helps to
evaluate taken samples, and saves them in a grid.

CLASSSIG
CORRELATION
DENDROGRAM
EDITSIG
EQUALTO

GEARY
GREATERTHAN

ISOCLUSTER

LESSTHAN

LPOS

creates an ASCII signature file that contains

signatures of classes, defined as class samples in

the input grid, in the input stack.

calculates the cross correlation between two input

grids and prints the correlation coefficient to the

screen.

constructs a tree diagram showing the distances
between sequentially merged classes in a
signature file.

edits a signature file by merging, renumbering
and deleting class signatures and creates a new
signature file.

evaluates, on a cell-by-cell basis, the number of
times in an argument list that the input grid
values are equal'to the value specified by the first
argument.

calculates the Geary spatial autocorrelation index
for a grid and prints it to the screen,
evaluates, on a cell-by-cell basis, the number of
times in an argument list that the input grid
values are greater than the value specified by the
first argument.

uses an isodata clustering algorithm to determine
the characteristics of the natural groupings of
cells in a multi-dimensional space, and stores the
results in an ASCII signature file,
evaluates, on a cell-by-cell basis, the number of
times in an argument list that the input grid
values are less than the value specified by the first
argument.

determines, on a cell-by-cell basis, the position of
the input grid with the minimum value in the
argument list.

'iMailer Index Local :-;-v:-.- Go .: First-:b: Previous . Next f Print. ;j'.;Vlewer Ou'rt -
Contents;: : ::: Contents -v Back Page f." Page • ฆ ••Pago.:.-.-;.. ...--Heip'-vy-'-1

Master index ..: Local . Go First previous Next.'. Print ..Viewer. QuU
Contents'-1':':-;!:.. Contents B*ck Paye Page Page	.'Help

-------
A functional list of GRID commands

A functional list of GRID commands

MAJORITY uses multiple input grids to determine the

'majority' value (the value that appears most
often) on a cell-by-cell basis.

MAX uses multiple input grids to determine the
maximum value on a cell-by-cell basis.

MEAN uses multiple input grids to determine the mean
value on a cell-by-cell basis.

MED uses multiple input grids to determine the median
value on a cell-by-cell basis.

MIN uses multiple input grids to determine the
minimum value on a cell-'by-cell basis.

MINORITY uses multiple input grids to determine the

'minority1 value (the value that appears least
often) on a cell-by-cell basis.

MLCLASSIFY performs maximum likelihood classification on a
stack and creates the classification grid.

MORAN calculates the Moran spatial autocorrelation
index for a grid and prints it to the screen.

POPULARITY determines the value in an argument list that is
at a certain level of popularity on a cell-by-cell
basis within the analysis window. The particular
level of popularity (the number of occurrences of
each value) is specified by the first argument.

PRINCOMP generates a stack of layers being the principal
components of the input stack
RANK returns the value in the th position in the

rank order of the argument list, which is created
using the specified multiple input grids, on a cell-
by-cell basis.

REGRESSION outputs the regression coefficients for the
regression model in tabular form.

SAMPLESIG creates an ASCII signature file that contains a set
of statistics defining zones specified in the input
file.

STACKSTATS calculates the statistics for layers of a stack.

UPOS determines, on a cell-by-cell basis, the position of
the input grid with the maximum value in the
argument list.

VARIETY uses multiple input grids to determine the variety
of the values (the number of unique values) on a
cell-by-cell basis.

Miscellaneous functions

ABS calculates the absolute value of the input.

CEIL returns the next highest whole value that is
greater than or equal to the input values.

CON performs one or more conditional if/else
evaluations.

FLOAT converts integer values to floating-point values.

FLOOR returns the greatest integer value that is smaller
than or equal to the input values.

FMOD divides the values of the first input by the second
input and returns the remainder on a cell-by-cell
basis.

INT converts input floating-point values to integer
values through truncation.

ISNULL returns '1' if the input value is NODATA, and '0' if
it is not.

MERGE merges multiple, possibly nod-adjacent input

grids into a single grid based upon order of input.

MOSAIC merges multiple adjacent continuous grids and
performs interpolation in the overlapping areas
NORMAL creates a grid with randomly dispersed values of a
normal distribution.

PICK using the values of an input grid, determines
which expression will be used, and uses it to
compute the output values.

RAND generates a random number between '0' and '1'.

10

•; MasterIndex.,

local i:.\

:il Goi '' V

P'First.::

; Previous

^Next

Print.;-Viewer

•KQuii

Contents''

Contents'

•i-Back'

:>Page.:

Pago-;>

"Pago





A functional list of GRID commands

A functional list of GRID commands

SAMPLE lists the values of a group of cells from one or
more grids.

SCALAR returns the result of a map algebra expression

involving numbers as a numeric value that can be
assigned to a scalar variable.

SETNULL returns NODATA if the evaluation of the input
condition is TRUE'; if it 'FALSE', returns the
value specified by the second input argument.

Focal functions

FOCALFLOW determines the flow of the values in the input grid
within each cell's immediate neighborhood.

FOCALMAJORITY for each cell location on an input grid, finds the
'majority' value (the value that appears most
often) within a specified neighborhood and sends
it to the corresponding cell location on the output
grid.

FOCALMAX for each cell location on an input grid, finds the

highest value within a specified neighborhood and
sends it to the corresponding cell location on the
output grid.

FOCALMEAN for each cell location on an input grid, finds the
mean of the values within a specified
neighborhood and sends it to the corresponding
cell location on the output grid.

FOCALMEDIAN for each cell location on an input grid, finds the

median value within a specified neighborhood and
sends it to the corresponding cell location on the
output grid.

FOCALMIN for each cell location on an input grid, finds the
minimum value within a specified neighborhood,
and sends it to the corresponding cell location on
the output grid.

FOCALRANGE for each cell location on an input grid, finds the
range of the values within a specified
neighborhood and sends it to the corresponding
cell location on the output grid.

FOCALSTD for each cell location on an input grid, finds the

standard deviation of the values within a specified
neighborhood and sends it to the corresponding
cell location on the output grid
FOCALSUM for each cell location on an input grid, adds the

values within a specified neighborhood and sends
the sum to the corresponding cell location on the
output grid.

FOCALVARIETY for each cell location on an input gnd, determines
the number of unique values (or the variety)
within a specified neighborhood and sends it to
the corresponding cell location on the output grid

Zonal (unctions

ZONALAREA calculates the area of each zone in the input grid.

ZONALCENTROID creates a grid with cells locating the geometric
centers of each zone of an input gnd
ZONALFILL fills zones using the minimum cell value from a
weight gnd, along the zone boundary.

ZONALGEOMETRY records in an output INFO table the area,

perimeter and thickness of the values of all cells
m an input grid that belong to the same zone.

ZCh ALMAJORIT Y records in each output cell the majority value (the
value that appears most often) of all cells in the
 that belongs to the same zone as the
output cell. Zones are identified by the values of
the cells in the input .

ZONALMAX records in each output cell the max mi urn value of
all cells in the cvalue_grid> that belong to the

11

•Master'.'' Index -Uocal. Previous - Neict Prim ' Viewer (hut
Contents;'';^-1.-':' * ,Contentป'ot BiCk^V'.Page	~ Page	* Help

Index Local *ฆ* Go FirstPrevious- Nซx1'. -' ฆ.... Print ^-Viewer * << Quit"
Contents	Contents'' Back Page ; : Page/ . , Pagev	'Help *

-------
A functional list of GRID commands

A functional list of GRID commands

same zone as the output cell. Zones are identified
by the values of the cells in the input .

ZONALMEAN records in each output cell the mean of the values
of all cells in the  that belong to the
same zone as the output cell. Zones are identified
by the values of the cells in the input .

ZONALMEDIAN records in each output cell the median value of all
cells in the  that belongs to the same
zone as the output cell. Zones are identified by the
values of the cells in the input .

ZONALMIN records in each output dell the minimum value of
all cells in the  that belong to the
same zone as the output cell. Zones are identified
by the values of the cells in the input .

ZONALPERIMETER calculates the perimeter of each zone in the input
grid.

ZONALRANGE records in each output cell the range of values of
all cells in the  that belong to the
same zone as the output cell. Zones are identified
by the values of the cells in the input .

ZONALSTATS records in an output INFO table the minimum,
maximum, range, sum, mean, standard deviation
and variety of the values of all cells in the
 that belong to the same zone. Zones
are identified by the values of the cells in the
input .

ZONALSTD records in each output cell the standard deviation
of the values of all cells in the  that
belong to the same zone as the output cell. Zones
are identified by the values of the cells in the
input .

ZONALSUM records in each output cell the sum of the values
of all cells in the  that belong to the
same zone as the output cell. Zones are identified
by the values of the cells in the input czone_grid>.

13

ZONALTHICKNESS calculates for each zone on an input grid the

deepest or thickest point within the zone from its|
surrounding cells.

ZONALVARIETY records in each output cell the variety of values
(the number of unique values) of all cells in the
 that belong to the same zone as the
output cell. Zones are identified by the values of
the cells in the input .

Block functions

BLOCKMAJORITY an aggregation function that partitions the input
grid into blocks and finds the majority of the
values for the specified cells (defined by the
neighborhood parameters) within the block and
sends it to each cell location in the block on the
output grid.

BLOCKMAX an aggregation function that partitions the input
grid into blocks and finds the highest value for the
specified cells (defined by the neighborhood
parameters) within the block and sends it to each
cell location in the block on the output grid.

BLOCKJ/EAN an aggregation function that partitions the input
grid into blocks and finds the mean value for the
specified cells (defined by the neighborhood
parameters) within the block and sends it to each
cell location in the block on the output grid.

BLOCKMEDIAN an aggregation function that partitions the input
grid into blocks and finds the median value for the
specified cells (defined by the neighborhood
parameters) within the block and sends it to each
cell location in the block on the output grid.

BLOCKMIN an aggregation function that partitions the input
grid into blocks and finds the smallest value for
the specified cells (defined by the neighborhood

Master..:-Intfox v i.vLocal	previous Next

Contents/.1 ;P/-:ContantR;/'.8ack\ Page ••'V'/Pago/V^Pago^v

; MasteryIndex ;• Local;Go
Contents;':':-.;- Contents''''--- Back/

First /-.'.- PreviousNext •••
Page.xV:Pagr ;'::;-.-P30e.'..

Print Viewer
Help

A functional list of GRID commands

A functional list of GRID commands

parameters) within the block and sends it to each	COSTBACKLINK

cell location in the block on the output grid.

BLOCKRANGE an aggregation function that partitions the input

grid into blocks and finds them range of values for	COSTDISTANCE

the specified cells (defined by the neighborhood
parameters) within the block and sends it to each

cell location in the block on the output grid.	COSTPATH

BLOCKSTD an aggregation function that partitions the input
grid into blocks and finds the standard deviation
of values for the specified cells (defined by the
neighborhood parameters) within the block and
sends it to each cell location in the block on the

output grid.	EUCALLOCATION

BLOCKSUM an aggregation function that partitions the input

grid into blocks and finds the sum of values for the	EUCDIRECTION

specified cells (defined by the neighborhood
parameters) within the block and sends it to each
cell location in the block on the output grid.

BlOCKVARiETY an aggregation function that partitions the input

grid into blocks and finds the variety of the values	EUCDISTANCE

(the number of different values) for the specified

cells (defined by the neighborhood parameters)	PATHDISTANCE

within the block and sends it to each cell location
in the block on the output grid.

Distance functions

CORRIDOR records for each cell location the sum of the

accumulative costs for two input accumulative-	COMBINE

cost grids.

COSTALLOCATION identifies for each cell the zone of each source cell
that could be reached with the least accumulative
cost.

DOCELL

defines the neighbor that is the next cell on the
least-accumulative-cost path from a cell to a set of
source cells.

calculates for each cell the least-accumulative-
cost distance over a cost surface to a source cell or
a set of source cells.

produces an output grid that records the least-cost
path(s) from selected celKs) in the input
, or from interactive selection on
the display, to the closest source cell defined
within the  in terms of cost
distance.

calculates for each cell the zone of the closest
source cell (in Euclidean distance),
calculates the direction in degrees that each cell
center is from the cell center of the closest source.
The output values are based on compass
directions, with 0* being reserved for the source
cells.

calculates for each cell the Euclidean distance to
the closest source.

calculates, for each cell, the least-accumulative-
cost distance over a cost surface from a source cell
or a set of source cells while accounting for surface
distance and horizontal and vertical cost factors

Combinatorial functions
combines multiple grids on a cell-by-cell basis,
such that a unique output value is assigned to
each unique combination of input values

Conditional statements

controls per-cell processing on a cell-by-cell basis

Master ln
-------
A functional list of GRID commands

A functional list of GRID commands

IF performs a conditional ltfelse evaluation on a cell-
by-cell basis.

WHILE repeats a statement list body as long as the tested
condition is a semi-Boolean TRUE value
(nonzero).

GRID management commands

ABBREVIATIONS turns command abbreviations on or off.

ADDTOSTACK adds one or more grids to a stack.

AP allows entry of ARCPLOT commands directly
from the Grid: prompt.

ARCTOOLS invokes the ARC/INFO menu interface.

ATUSAGE returns the usage for ATOOL commands.

BU1LDSTA builds a statistics file (STA) for a grid based upon,
the VALUE item.

BUILDVAT builds a value attribute table (VAT) for a grid.

COMMANDS lists available GRID commands or just those
commands which begin with (prefix).

COPY duplicates a grid. All information associated with
the grid is duplicated.

COPYSTACK copies a stack including its component grids to a
new stack.

DESCRIBE provides a detailed description of a grid and its
contents.

DROPFROMSTACK eliminates one or more grids from a Btack.

EXTERNAL corrects external file pathnames for a geographic
data set's INFO data files.

EXTERNAL-ALL recursively finds all subdirectories under the

specified directory and corrects the external file
pathnames of the INFO data files for all
geographic data sets found in all workspaces.

FORMEDIT starts the graphical form editor for AML form

INDEX ITEM
INFO

KILL
LIST

LISTCOVERAGES
LISTGRIDS
L1STIMAGES,

LISTSTACKS
LOG

MAKESTACK
MERGEVAT

PRINT
PROJECT-
COMPARE
QUIT

REMOVESCALAR
RENAME
RESET

RESTORE

SAVE
SETCELL

SETMASK

creates an attribute index to increase access speed
to the specified item during query operations,
begins execution of the INFO subsystem for ARC
using the INFO subdirectory in the current user
workspace,
deletes a grid.

lists the item values for all records of the specified
INFO data file.

, lists the coverages contained in a workspace
lists the grids contained in a workspace,
lists the images contained in a workspace and,
optionally, their type.

lists the stacks contained in the workspace,
lists the contents of a log file or add a new entry to
the log.

generates a stack from a given set of grids,
merges the value attribute tables, VATs, of two
grids.

prints the results of an expression to the screen
sets the comparison level of the present session.

stops execution of the GRID system and returns

control to the ARC system.

removes or deletes a scalar variable.

changes the name of a grid.

re-initializes the GRID analysis environment to

the default settings.

restores the GRID analysis environment to the
settings stored in an environment file,
saves the current GRID analysis environment,
sets the cell size of the current analysis
environment.

sets the mask of the current analysis
environment.

1?	18

i'Master=•;.Indexop Local Go. . First • Previous '. Next ' Print Viewer'....;..Master^';.'.'Index ,y..-::LocalGo•=ฆ• Firsii^VPrevious'.-• Next = Print Viewer...Quit
Back-NV v;:;Page.>%Page.:f -• Paga •	•' Help, :	Contenis. ;i'...:. '; 'Contentsv^.Back.• •H.'Page'/v!-',' Paga.^^Page'^^^

A functional list of GRID commands	A functional list of GRID commands

sETWINDOW sets the window of the current analysis
environment.

SHOW lists the current setting of the user workspace,
display device, method of coordinate input, or
digitizer on your terminal screen.

STATUS shows the status of the current GRID analysis
environment.

USAGE returns the usage of the specified command
VERIFY sets the automatic verification of answers to
system prompts.

Geometric transformation
In ARC

CONTROLPOINTS

GRIDDESKEW

ADJUST

FLIP
LLSFIT

MIRROR
PROJECT

RESAMPLE

initiates an interactive program that allows the
user to create a link file by graphically choosing
from and to points. Also allows the user to
interactively evaluate the goodness of fit of
different polynomial transformations for the
selected links.

corrects common distortions in scanned
documents.

In GRID

adjusts or rubber sheets a grid in either direction

along the links from a separate link coverage.

flips a grid along a horizontal axis.

performs a linear least-squares fit to a link file or

link coverage and reports the RMS error and

coefficients.

mirrors a grid along a vertical axis

projects coordinates between two projections for a

grid.

changes the cellsize of a grid.

ROTATE rotates a grid around the lower left comer by a
specified angle.

SHIFT shifts the coordinates of a grid, and optionally
changes the cell size.

WARP rubber sheets a grid along a set of links using a
polynomial transformation.

Color model conversion

COLOF12BLUE converts a grid and associated colormap into a

grid representing the RGB blue components of the
input.

COLOR2GREEN converts a grid and associated colormap into a
grid representing the RGB green components of
the input.

COLOR2HUE converts a grid and associated colormap into a

grid representing the HSV hue components of the
input.

COLOR2RED converts a grid and associated colormap into a

grid representing the RGB red components of the
input

COLOR2SAT converts a grid and associated colormap into a

grid representing the HSV saturation components
of the input.

COLOR2VAL converts a grid and associated colormap into a
grid representing the HSV value components of
the input.

HSV2BLUE converts three grids representing the hue,

saturation, and value of an HSV color model to a
blue grid for an RGB color model

HSV2GREEN converts three grids representing the hue,

saturation, and value of an HSV color model to a
green grid for an RGB color model.

'•Master.-v-.'.'.': index';



iv Go :•=

Frsl

Previous i

i Next „•

>: Print Viewer

' Quit

Contents

Contents

'..Back:.:

s''3".Page-s

Page .

•j Page .-;ii

Help



• Master index . -'-Local••.•Go :• i-iFlrst ^Previous NextPrint ^Vilevver^?:Qu!t-:
Contents..rv:'.:sV ; Contents '. Back Page.^x Page Page	\Hetp: ,>

-------
A functional list of GRID commands

A functional list of GRID commands

HSV2RED converts three grids representing the hue,

saturation, and value of an HSV color model to a
red grid for an RGB color model.

RGB2HUE converts three grids representing the red, green,
and blue of an RGB color model to a hue grid for
an HSV color model.

RGB2SAT converts three grids representing the red, green,
and blue of an RGB color model to a saturation
grid for an HSV color model.

RGB2VAL converts three grids representing the red, green,
and blue of an RGB color'model to a value grid for
an HSV color model.

Surface functions and commands
In ARC

TOPOGRID generates a digital elevation model from
coverages of elevation.

TOPOGR1DTOOL menu driven interface for the TOPOGRID
command.

In GRID

ASPECT identifies the direction of maximum rate of change
in z value from each cell.

CURVATURE calculates the curvature of a surface at each cell
center.

HILLSHADE creates a shaded relief grid from a grid by
considering the sun illumination angle and
shadows.

IDW performs an inverse distance weighted
interpolation on a point data set.

KRIGING interpolates a point data set into a surface using
kriging.

21

SAI creates an output grid containing a slope-aspect
index, or a lookup table of hypothetical solar
illumination to be used for displaying such a grid

SLOPE identifies the rate of maximum change in z value -
from each cell.

SPLINE performs a spline interpolation on a point data set
resulting in a smoothed surface with the
minimum curvature.

TREND performs a trend interpolation on a point data set.

Shape analysis functions

EXPAND expands the selected zones by a specified number
of cells.

REGIONGROUP records for each cell in the output the identity of
the connected region to which it belongs. A unique
number is assigned to each region.

SHRINK shrinks the selected zones by a specified number
of cells.

Editing commands

BRUSH changes cell values in a manner similar to
stroking on paint with a paintbrush.

COLORS specifies how to draw the grid.

DRAW displays images and grids specified in the current
draw environment.

DrawBox draws a box on the grid.

DrawCircte draws a circle on the grid.

DRAWING sets the draw environment for the edit grid.

DrawLine draws a line on the grid.

DrawPolygon draws a polygon on the grid.

EDIT specifies the name of the grid to edit.

ENHANCE applies an enhancing filter to the selected area.

FillBox fills a box on the grid.

FillCEII changes the value of an individual cell on the grid.

22

Master.

; IndexLocal

Go

First

.Previous.;

Next

= Print 'Viewer

Quit

Contents:

; Contents.

Back

Page

Pagซ;'v

Pagฎ.,

Help



.'Master /.Index; local
Conttnts	Contents -;:;:.Back..

•:First --Previous
'i-'Page ^Paga

A functional list of GRID commands

A functional list of GRID commands

FillCircle fills a circle on the grid.

FillPolygon fills a polygon on the grid.

FillRegion changes the value of a connected group of cells.

FillType specifies how cell values are assigned to filled
areas.

FillValue sets the cell value for filling areas and drawing
lines.

FilterSizo sets the neighborhood size for the enhancement
filters.

FLIP flips the selected area along a horizontal axis.

GET copies the selected area from another grid into the
current edit grid.

GndMErge merges the specified grids into the current edit
grid.

IMAGE displays an image or a group of images from an
image catalog.

UneWidth sets the width for drawing lines.

MIRROR mirrors the selected area along a vertical axis

MOVE moves the selected area.

OOPS undoes changes made to the edit grid
OOPSOFF disables the oops environment.

OOPSON activates the oops environment.

PREForences sets the editing preference for operations that

change the orientation or position of the selected
area.

PUT copies the selected area into another edit grid.

QUIT terminates the current grid editing session.

RegionRemove eliminates raster features whose cell count falls
between a threshold minimum and maximum
value.

RegionSample sets the threshold minimum and maximum cell
counts for eliminating raster features.

REMAP applies a contrast stretch to enhance grid display
RemoveEdit removes edit grids from the current editing
session

23

ROTATE	rotates the selected area.

SAVE	saves changes made to an edit grid.

SELectAII	selects the entire grid.

SELectBox	selects all cells contained by a box

SELectCircle	selects all cells contained by a circle.

SELectCLear	clears the selected area.

SELeclPolygon	selects all cells contained by a polygon.

SMOOTH	applies a smoothing filter to the current selected
area.

SPecKleRemove	eliminates noise within the selected area.

SPecKleSize	sets the size of speckles to remove.

Data cleanup functions

BOUNDARYCLEAN smooths the boundary between zones by
expanding and shrinking the boundary.

MAJORITYFILTER replaces cells in a grid based upon the majority of
their contiguous neighboring cells.

NIBBLE replaces areas in a grid corresponding to a mask,
with the values of the nearest neighbors.

THIN thins rasterized linear features by reducing the
number of pixels representing the width of the
features.

Hydrologic functions

BASIN creates a grid delineating all drainage basins
within the analysis window.

DARCYFLOW calculates the groundwater volume balance

residual for steady state flow in an aquifer and
the seepage velocity for each cell using Darcy's
Law.

FILL fills sinks or levels peaks in a continuous grid to
remove small imperfections in the data.

:Mast* Index

Local

Go

First

Previous

..NtXt

Print: .Viewtr 
-------
A functional list of GRID commands

A functional list of GRID commands

FLOWACCUM- creates a grid of accumulated flow to each cell,
ULATION by accumulating the weight for all cells that flow
into each downslope cell.

-LOWDi RECTI ON creates a grid of flow direction from each cell to its
steepest downslope neighbor.

FLOWLENGTH calculates distance, or weighted distance along a
flow path.

PARTICLETRACK calculates the path of a particle through a velocity
field.

POROUSPUFF calculates the time-dependent, two-dimensional
concentration distribution of a solute, introduced
instantaneously at a discrete point into a
vertically mixed aquifer.

SINK creates a grid identifying all sinks, or areas of
internal drainage.

SNAPPOUR snaps selected pour points to the cell of highest
flow accumulation within a specified
neighborhood.

STREAMLINE converts a grid representing a raster linear
network to a line coverage.

STREAMLINK assigns unique values to sections of a raster linear
network between intersections.

STREAMORDER assigns a numeric order to segments of a grid
representing branches of a linear network.

WATERSHED determines the contributing area above a set of
cells in a grid.

Visibility tools

VISDECODE returns a list of observation points that can be

seen by cell locations with a specified value in the
VALUE item of the output grid from the
VISIBILITY function.

VISENCODE returns the VISIBLE-CODE value or values that
are assigned to each cell location on the output
grid created by the VISIBILITY function which
can be seen by up to sixteen specified points

VISIBILITY performs visibility analysis on a grid by

determining how many observation points can be
seen from each cell location of the input grid, or
which cell locations can be seen by each
observation point.

Data conversion
in ARC

ASCIIGRID converts an ASCII file to a grid.

ADRGGRID converts ADRG data into a grid.

DEMLATTICE converts a DEM in USGS or TAME format to a
lattice.

DTEDGRID converts a US DMA DTED file into a grid.

FLOATGRID converts a file of binary floating point numbers
into a grid.

GRIDASC1I converts a grid to an ASCII file.

GRIDFLOAT converts a cell value of a grid into a file of binary
floating point numbers.

GRIDIMAGE converts a grid into the specified output image
format.

GRIDMOSS converts a grid into a MOSS raster export file.

GRIDSVF converts a grid to an ARC/INFO single-variable
file (SVF).

IMAGEGRID converts an image into a grid or set of grids.

LATTICEDEM converts a lattice to a DEM in USGS format.

MOSSGRID converts a MOSS raster export file into a grid.

SVFGRID converts an ARC/INFO single-variable file into a
grid.

. Master ..A Index ฆ• Local i-Sv -Go . pi: First - ^. Previous ••. Next Print Viewer-1 •. Quit .•
Conient$"ง\:'j-''-- -"Conten1ฎ Back Page .Page Page, ^: :.Htelp = .

A functional list of GRID commands

A functional list of GRID commands

In GRID

GRIDLINE converts a grid representing rasterized linear
features to a line coverage.

GRIDPOINT converts a grid representing raster point features
into a point coverage.

GRIDPOLY converts a grid to a polygon coverage.

LINEGRID creates a grid from line features in a coverage.

POINTGRID creates a grid from points in a coverage.

POLYGRID creates a grid from polygons in a coverage.

Grid display
In ARCPLOT

CELLVALUE returns the value and attributes for the cell
containing a specified point.

IMAGE displays a raster image or a group of images from
an image catalog on the screen.

GRIDCOMPOSITE displays three grids as a composite image.

GRIDDIRECTION draws arrows whose direction is determined by
the values of grid cells.

GRIDNET draws a fishnet or mesh of lines delineating the
boundary of cells in a grid, or the boundary of a
grid.

GRIDNODATA- sets the shade symbol or colormap index for
SYMBOL displaying grid cells with NODATA.

GRIDPAINT displays a grid using the item value, stretch or
lookup table, and an ASCII colormap file.

GRIDQUERY displays the set of cells in a grid that satisfy a
logical expression.

GRIDSHADES shades a grid using a symbolized or transformed
item value to determine color.

DRAWSIG
DRAWZONESHAPE
HISTOGRAM
LOADCOLORMAP
SAVECOLORMAP
SCATTERGRAM

SHADEGRID

STACKHISTOGRAM

STACKSCATTER-
GRAM

STACKSHADE

In GRID

displays class signatures as ellipses in a two
dimensional graph

draws ellipses approximating the shape and
orientation of each zone.

displays the frequency distribution of values in a
grid.

loads the colors of an ASCII colormap file into the
current shadeset.

saves the colors corresponding to symbols in the
current shadeset to an ASCII colormap file,
displays a graph showing in a two dimensional
space the distribution of one grid's cells' values
against another grid.

a menu-based tool for generating shade sets and
remap tables that can be used to create a custom
display of a grid.

displays a set of histograms, ones for each layer of
a stack.

displays a set of graphs, one for each pair of a
stack's layers, showing in a two dimensional space
the distribution of cell values
displays all layers of a stack in a layout fashion
using the current shade set.

Muter Index Ueal Co First .Previous Ntxt Prim 7;Vi*w*r:ifc.Qulli::
Contents ; . Contents ,• Beck Page Page' "Page - '^SSHeip

27

Matter Index Ueป! Go First Previous Next Print . : Viซwซr Quit
Contents	Contents Back • Page Page Page 'iifcs's Helpiiltefefe';-

-------