spatial analyst for geospatial intelligence - amazon s3 · spatial analyst for geospatial...

57

Upload: buitruc

Post on 06-Jul-2018

244 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,
Page 2: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Spatial Analyst for Geospatial IntelligenceSpatial Analyst for Geospatial Intelligence

Chris BelsonChris Belson

Page 3: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

OverviewOverview

•• Introduction to ArcGIS Spatial AnalystIntroduction to ArcGIS Spatial Analyst–– What is Spatial AnalystWhat is Spatial Analyst–– Why use raster dataWhy use raster data–– Choosing an environmentChoosing an environment

•• Accessing Spatial Analyst capabilitiesAccessing Spatial Analyst capabilities–– The seven interfacesThe seven interfaces–– Environment setting optionsEnvironment setting options

•• Basic Spatial Analyst ConceptsBasic Spatial Analyst Concepts–– The language of raster analysisThe language of raster analysis–– Spatial Analyst functionsSpatial Analyst functions

•• Modeling Modeling –– What are modelsWhat are models–– Types of modelsTypes of models

•• Calculating riskCalculating risk•• QuestionsQuestions

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 22

Page 4: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

ArcGIS Spatial AnalystArcGIS Spatial Analyst

•• Extension for ArcGIS Extension for ArcGIS DesktopDesktop

•• Provides rich modeling Provides rich modeling environmentenvironment

–– Derive new informationDerive new information–– Identify spatial relationshipsIdentify spatial relationships–– Find suitable locationsFind suitable locations–– Calculate travel costCalculate travel cost–– Works with all cellWorks with all cell--based based

GIS dataGIS data

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 33

Surfaces

Shelter locations

Suitable new Shelter locations

Page 5: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Why use raster data?Why use raster data?

•• Easier than vector in many analysisEasier than vector in many analysis•• Efficient overlays with complex dataEfficient overlays with complex data

–– The ability to uniformly store points, lines, polygons, and The ability to uniformly store points, lines, polygons, and surfacessurfaces

•• More analysis optionsMore analysis options–– The ability to represent continuous surfaces and perform The ability to represent continuous surfaces and perform

surface analysis (visibility, slope, aspect, etc. )surface analysis (visibility, slope, aspect, etc. )–– Distance analysis (decay distances, weighted distance Distance analysis (decay distances, weighted distance

etc.)etc.)•• Can be faster then some vector analysis!Can be faster then some vector analysis!

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 44

Page 6: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Raster datasetsRaster datasets

•• Raster data basicsRaster data basics–– Smallest unit of data is the cellSmallest unit of data is the cell–– Each cell has a numeric valueEach cell has a numeric value–– Cells are arranged inCells are arranged in

columns and rowscolumns and rows•• Each cell is independentEach cell is independent

–– No discrete features or attributesNo discrete features or attributes–– Raster is arbitrarily subdividedRaster is arbitrarily subdivided

for storagefor storage•• Data typeData type

–– Discrete data indicates a quantity of a variableDiscrete data indicates a quantity of a variable–– Continuous data indicates a quality of a variableContinuous data indicates a quality of a variable

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 55

Cell

1000 columns

1000 rows

Page 7: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Raster formatsRaster formats

•• The format is how cells are stored in a rasterThe format is how cells are stored in a raster•• ArcGIS supports dozens of raster formatsArcGIS supports dozens of raster formats

–– Various image formats Various image formats (SID, IMG, TIFF, and more)(SID, IMG, TIFF, and more)

–– ESRI grid and grid stackESRI grid and grid stack–– ESRI ArcSDE raster ESRI ArcSDE raster

•• All may be managed in ArcCatalog All may be managed in ArcCatalog •• Majority can be used with ArcGIS Spatial Majority can be used with ArcGIS Spatial

Analyst toolsAnalyst tools

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 66

Tank.gif CentralPark.img

TacticalForce.jpg

Page 8: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Raster format essentialsRaster format essentials

•• All raster formats are basically the sameAll raster formats are basically the same–– Content is more important than format: data or picture?Content is more important than format: data or picture?–– Spatial Analyst does not know the differenceSpatial Analyst does not know the difference

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 77

columnsro

ws

A

Raster data• Elevation• Land use codes• Population densityGood for analysis• Slope from elevationGood for mapping• Thematic layers• Derivative products

(like shaded relief)

Raster pictures• Scanned maps• Satellite images

(unclassified)• Photos of buildingsGood for mapping• BackgroundsGood for attributes• Picture of houseBad for analysis

Scanned map

Elevation

Page 9: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Raster compression Raster compression

•• Reduces storage and speeds drawingReduces storage and speeds drawing•• Compression is a property of a formatCompression is a property of a format

–– Cannot just compress a raster; you must change its formatCannot just compress a raster; you must change its format

•• Most raster formats support compressionMost raster formats support compression–– TIFF and GIF: LZW compression (lossless)TIFF and GIF: LZW compression (lossless)–– ArcSDE: LZ77, JPEG (lossy), or JPEG 2000 comp. (lossy*)ArcSDE: LZ77, JPEG (lossy), or JPEG 2000 comp. (lossy*)–– MrSID: Wavelet compression (lossy or lossMrSID: Wavelet compression (lossy or loss--less)less)–– ESRI gridESRI grid

•• Integer: Adaptive runInteger: Adaptive run--length encoding (losslength encoding (loss--less)less)•• Floating point: NoneFloating point: None

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 88

Page 10: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

OverviewOverview

•• Introduction to ArcGIS Spatial AnalystIntroduction to ArcGIS Spatial Analyst–– What is Spatial AnalystWhat is Spatial Analyst–– Why use raster dataWhy use raster data–– What is raster dataWhat is raster data

•• Accessing Spatial Analyst capabilitiesAccessing Spatial Analyst capabilities–– The seven interfacesThe seven interfaces–– Environment setting optionsEnvironment setting options

•• Basic Spatial Analyst ConceptsBasic Spatial Analyst Concepts–– The language of raster analysisThe language of raster analysis–– Spatial Analyst functionsSpatial Analyst functions

•• Modeling Modeling –– What are modelsWhat are models–– Types of modelsTypes of models

•• Calculating riskCalculating risk•• QuestionsQuestions

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 99

Page 11: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Seven interfaces for ArcGIS Spatial AnalystSeven interfaces for ArcGIS Spatial Analyst

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 1010

A

ArcToolbox1. ArcToolbox

Dialogs for all toolsCommand Line 2. Command LineType commands

Mod

elB

u ild

er 3. ModelBuilderVisual modeling

Scri pt s 4. ScriptsWrite easy programs

Toolbar

Spa tial Analyst

5. Spatial Analyst ToolbarDialogs for common tools

ArcObj

ects

6. ArcObjectsMore programming power

Map AlgebraTools

7. Map Algebra ToolsFor all interfaces

Map AlgebraTools

MapAlgebra

Most become Map Algebra

RasterEngine

Evaluated by Raster EnginePart of the geoprocessing framework(share a common environment)

Page 12: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Choosing an environmentChoosing an environment

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 1111

ToolToolDialogDialog Command LineCommand Line ModelModel

BuilderBuilder ScriptScript

Simple tasksSimple tasks

EfficientEfficient

ReusabilityReusability

Combine processesCombine processes

Batch operationsBatch operations **Use logicUse logic ****Schedule runtimeSchedule runtime

* Some tools have batch options.** Can set preconditions in model to set tool order.

Page 13: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Raster analysis environmentsRaster analysis environments

•• Control how an output raster is createdControl how an output raster is created–– Set for geoprocessing and ArcGIS Spatial Analyst toolbarSet for geoprocessing and ArcGIS Spatial Analyst toolbar——

independentindependent

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 1212

The output rasterThe input raster

ProjectionMask

Cell size Extent

Output Workspace

Page 14: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Setting geoprocessing environmentsSetting geoprocessing environments

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 1313

A

Spatial Reference

Extent & snapping

Cell size & mask

Workspaces

Spatial Reference

Extent

Cell size & mask

Page 15: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Setting output extentSetting output extent

•• Controls the width and height of the output rasterControls the width and height of the output raster–– Combine rasters with different extents; output another extentCombine rasters with different extents; output another extent

•• Output optionsOutput options–– Union of inputsUnion of inputs

(default)(default)–– Intersection of inputsIntersection of inputs–– Same as layerSame as layer–– Same as displaySame as display–– As specifiedAs specified

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 1414

Union of inputs

In 1 In 2

Out

In 1 In 2

Out

Intersection of inputs

Page 16: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Setting output cell sizeSetting output cell size

•• Rasters are resampled during analysisRasters are resampled during analysis–– Combine rasters with different cell sizes, output another sizeCombine rasters with different cell sizes, output another size

•• Output optionsOutput options–– Maximum of inputsMaximum of inputs

(default)(default)–– Minimum of inputsMinimum of inputs–– Same as layerSame as layer–– As specifiedAs specified

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 1515

Maximum of inputs

25 m

10 m

25 m

Minimum of inputs

25 m

10 m

10 m

Page 17: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Setting analysis maskSetting analysis mask

•• Defines areas where analysis is performedDefines areas where analysis is performed–– Useful for clipping to irregular shapesUseful for clipping to irregular shapes

•• Vector maskVector mask–– Only cells covered by featuresOnly cells covered by features

are output (others set to NoData)are output (others set to NoData)–– Creates a feature mask with Creates a feature mask with

selection and exportselection and export•• Raster maskRaster mask

–– Only cells covered by valued cellsOnly cells covered by valued cellsare output (others set to NoData)are output (others set to NoData)

–– Creates a raster mask with severalCreates a raster mask with severalArcGIS Spatial Analyst techniquesArcGIS Spatial Analyst techniques

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 1616

Mask

Input

Output

NoData

Page 18: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Setting output projectionSetting output projection

•• Rasters can be projected during analysisRasters can be projected during analysis–– Combine rasters in different projections, output to anotherCombine rasters in different projections, output to another

•• Output optionsOutput options–– Same as inputSame as input–– Same as displaySame as display–– Same as layerSame as layer

(geoprocessing only)(geoprocessing only)–– As specifiedAs specified

(geoprocessing only)(geoprocessing only)•• Uses Uses Fast projectFast project

–– Best for small areas at low latitudesBest for small areas at low latitudes

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 1717

Mercator

Albers

Page 19: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

OverviewOverview

•• Introduction to ArcGIS Spatial AnalystIntroduction to ArcGIS Spatial Analyst–– What is Spatial AnalystWhat is Spatial Analyst–– Why use raster dataWhy use raster data–– What is raster dataWhat is raster data

•• Accessing Spatial Analyst capabilitiesAccessing Spatial Analyst capabilities–– The seven interfacesThe seven interfaces–– Environment setting optionsEnvironment setting options

•• Basic Spatial Analyst ConceptsBasic Spatial Analyst Concepts–– The language of raster analysisThe language of raster analysis–– Spatial Analyst functionsSpatial Analyst functions

•• Modeling Modeling –– What are modelsWhat are models–– Types of modelsTypes of models

•• Calculating riskCalculating risk•• QuestionsQuestions

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 1818

Page 20: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Map Algebra: The language of rasterMap Algebra: The language of raster

•• A data manipulation language designed for rasterA data manipulation language designed for raster–– MathMath--like expressionslike expressions

Parts of the language:Parts of the language:–– Objects: Raster, vector, numbers, constants,and variablesObjects: Raster, vector, numbers, constants,and variables–– Operators: Operators: ““++””, , ““//””, , ““GTGT””, , ““LELE””, , ““ANDAND””, and , and ““OROR””–– Functions: Slope, FocalMean, and SinFunctions: Slope, FocalMean, and Sin–– Rules: For building expressions and using functionsRules: For building expressions and using functions

•• Most operators and functions are implemented as toolsMost operators and functions are implemented as tools

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 1919

LandingSuit = ([SlopeSuit] * 0.75) + ([PowerSuit] * 0.25)

Page 21: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Function syntax rulesFunction syntax rules

•• Functions return valuesFunctions return values–– Use as objects in expressionsUse as objects in expressions[PowerSuit] + CON([Slope] LE 15, 1, 0)

•• Arguments in parentheses and comma delimitedArguments in parentheses and comma delimitedSLOPE([Elevation], DEGREE)

•• Arguments may be other functions or expressionsArguments may be other functions or expressionsSLOPE( IDW(C:\data\elevpoints, spot), DEGREE)

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 2020

HILLSHADE (<grid>, {azimuth}, {altitude}, {ALL | SHADE | SHADOW}, {z_factor})

OptionalFunction Required Default Optional

Optional defaults 315 45 All 1.0

Page 22: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Expression evaluationExpression evaluation

•• How expressions are processedHow expressions are processed

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 2121

1.1. Define an empty output grid based on the analysis environmentDefine an empty output grid based on the analysis environment2.2. Position to the next output cell (start at row 0, column 0)Position to the next output cell (start at row 0, column 0)3.3. Resample input raster(s) to determine corresponding cell valuesResample input raster(s) to determine corresponding cell values4.4. Evaluate the expression and write the result to the output cellEvaluate the expression and write the result to the output cell5.5. Repeat Steps 2Repeat Steps 2––4 for all output cells4 for all output cells

= +

9

9

OutGrid

3

87096323

9 87 3 6 8 29 7 5 5 79 1 2 7 0

Layer1

6

6 9 7

2 4 1

6 0 5

Layer2

= +

Page 23: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Special cell values in Map AlgebraSpecial cell values in Map Algebra

•• Logical: Nonzero values are Logical: Nonzero values are TrueTrue; zero is ; zero is FalseFalse

•• NoData: If any input is NoData: If any input is NoDataNoData, the output is , the output is NoDataNoData

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 2222

Layer1

1 211 11 ND 1 21 1 21 22 2 2 2

22 2

2 2 22

2 222 22 2 2 22 2 12 22 2 1 1

21 1

1 ND 11

3 433 33 ND 3 43 3 33 44 4 3 3

43 3

3 ND 33

Layer2 Layer3

5 7-2-2 5-2 -2 5 55 5 50 00 4 4 4

77 7

4 7 77

1 111 11 1 1 11 1 10 00 1 1 1

11 1

1 1 11

T TTT TT T T TT T TF FF T T T

TT T

T T TT

As Values As True/False As logical 0,1

Page 24: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Map Algebra operatorsMap Algebra operators

•• Work with two objects, such as Work with two objects, such as Slope GE 10

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 2323

<, LT Less than<=, LE Less than or equal>, GT Greater than>=, GE Greater than or equal

==, EQ Equal∧=,<>, NE Not equal

Relational

−∗

/, DIV

+

MOD− Unary minus

SubtractionAddition

MultiplicationDivisionModulus

Arithmetic∧, NOT Logical complement&, AND Logical And⏐, OR Logical Or!, XOR Logical Xor

Boolean

CAND Combinatorial AndCOR Combinatorial OrCXOR Combinatorial Xor

Combinatorial

DIFF Logical differenceIN {list} Contained in list

OVER Replace

Logical

Page 25: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Examples of operatorsExamples of operators

•• Using EQ to find changes in land useUsing EQ to find changes in land use

•• Using OVER to update land useUsing OVER to update land use

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 2424

5 755 55 5 5 55 5 55 55 5 5 5

77 7

7 7 77

5 755 55 5 5 55 5 55 55 4 4 4

77 7

4 7 77

1 111 11 1 1 11 1 11 11 0 0 0

11 1

0 1 11

EQ

Landuse90 Landuse95 LuDiff

OVER

004

4 4 44

5 755 55 5 5 55 5 55 55 5 5 5

77 7

7 7 77

5 755 55 5 4 55 4 45 55 5 5 5

74 7

4 7 77

PoliceStation Districts90 DstUpdate

0 0 00 0 0 00 00 0 0 00 0 0 0 0

Page 26: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Multi Output Map Algebra toolMulti Output Map Algebra tool

•• Implements all Map Algebra capabilitiesImplements all Map Algebra capabilities–– Lacks some normal tool capabilitiesLacks some normal tool capabilities

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 2525

DISPOL = EUCDISTANCE ( POLICE )RISKPOL = CON( DISPOL LE 1000.0, 10000.0 - ( POW( DISPOL / 10.0, PI)), 0.0)

Multiple expressions

Constants andvariables OK

Must assign output Grid

Grid inputs only – no layersSame Spatial Reference

Syntax for operators,functions

Outputs not added tothe Table of Contents

Page 27: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Single Output Map Algebra toolSingle Output Map Algebra tool

•• Designed for use with ModelBuilderDesigned for use with ModelBuilder

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 2626

CON(DISPOL LE 1000.0, 10000.0 - ( POW( DISPOL / 10.0, 3.145)), 0.0)

C:\RasterData\RISKPOL

DISPOLPolice Stations

Any raster/layer inputAny spatial reference

Outputs are added tothe Table of Contents

Set inputs forModelBuilderparameters(optional)

Set output

No constants or variables

One expression Syntax for operators,functions

Page 28: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Map Algebra functionsMap Algebra functions

•• Do most of the work in Map AlgebraDo most of the work in Map Algebra–– Approximately 168 functionsApproximately 168 functions

•• Can classify functions by processing methodCan classify functions by processing method

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 2727

By cell

Local

By neighborhood

Focal

By raster

Global

By zone

Zonal

Page 29: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Local functionsLocal functions

•• Compute values based on the current output cellCompute values based on the current output cell–– Most functions are localMost functions are local

•• Each cell is processed, starting at top leftEach cell is processed, starting at top left

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 2828

Page 30: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

CON functionCON function

•• IFIF--THENTHEN--ELSE function for Map AlgebraELSE function for Map Algebra

•• May be a simple IFMay be a simple IF--THENTHEN--ELSEELSE

•• Or nest CONs for an ELSEOr nest CONs for an ELSE--IFIF

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 2929

CON(<condition>, <true_expression>, {false_expression})IF THEN (TEST = 1) ELSE (TEST = 0)TEST

CON(Slope < 20, 1, 0)

Third CON {false_expression}Second CON {false_expression}

CON(Slope < 20, 1,

CON(Slope < 40, 2,

CON(Slope < 90, 3, 5) ) )

Page 31: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Focal functionsFocal functions

•• Compute values by cell neighborhoodsCompute values by cell neighborhoods–– Writes result to current cell in the output gridWrites result to current cell in the output grid

•• Neighborhood is a moving window over inputNeighborhood is a moving window over input

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 3030

Page 32: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Neighborhood typesNeighborhood types

•• You can define the neighborhood geometryYou can define the neighborhood geometry

•• Create a custom neighborhood with a kernel fileCreate a custom neighborhood with a kernel file

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 3131

Default Rectangle Circle Annulus Wedge

FOCALSUM(Elev)

FOCALSUM(Elev, RECTANGLE, 5, 3)

FOCALSUM(Elev, CIRCLE, 2)

FOCALSUM(Elev, ANNULUS, 2, 3)

FOCALSUM(Elev, WEDGE, 4, 300, 330)

5 3

1 1 0 1 0

1 0 0 1 1

0 1 1 1 0

Kernel.txt

Page 33: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Zonal functionsZonal functions

•• Most summarize values in a layer by zones in anotherMost summarize values in a layer by zones in another–– Require two input rasters: Zone and ValueRequire two input rasters: Zone and Value

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 3232

Zone layer

Value layer

Output layer

District

Population

ZONALSUM(District, Population)ZONALSUM(District, Population)

PopByDistrict

Page 34: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Global functionsGlobal functions

•• Can access all input cells to compute output cell valueCan access all input cells to compute output cell value–– Interpolators (IDW, Spline others)Interpolators (IDW, Spline others)

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 3333

Page 35: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Distance functions Distance functions

•• StraightStraight--line distanceline distance–– Inputs: Sources (raster, point, line, or polygon)Inputs: Sources (raster, point, line, or polygon)–– Euclidean distance: Distance to threatened bridgeEuclidean distance: Distance to threatened bridge

•• Weighted distance Weighted distance –– Inputs: Sources and cost surfaceInputs: Sources and cost surface–– Cost distance: How long to drive to destinationsCost distance: How long to drive to destinations–– Cost path: Best paths to destinationsCost path: Best paths to destinations

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 3434

Page 36: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Calculating Euclidean distanceCalculating Euclidean distance

•• Calculates straightCalculates straight--line distanceline distance–– From each cell to nearest sourceFrom each cell to nearest source–– Cell center to cell centerCell center to cell center–– Output in map units (e.g., feet)Output in map units (e.g., feet)–– Source cells are output as zeroSource cells are output as zero

•• Must create sources firstMust create sources first

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 3535

.

.Distance

c b

aSource

(camp A)

Another cell

C = a + b2 2

Distance to source cells Distance to source cells

Page 37: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Weighted distance measurementWeighted distance measurement

•• The shortest path between points is not always the The shortest path between points is not always the bestbest

•• Finds the leastFinds the least--cost path between cells and sourcescost path between cells and sources–– Considers resistance to travel; an input cost surface Considers resistance to travel; an input cost surface –– Weights distance with travel costsWeights distance with travel costs

•• Result: Accumulated travel cost to every cellResult: Accumulated travel cost to every cell–– Units are cost (e.g., time, risk), not distanceUnits are cost (e.g., time, risk), not distance

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 3636

Five hours

Ten hours• Ten hours to climb over the mountain

• Five hours to follow the trail around it

Page 38: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Roadmap: Weighted distance processRoadmap: Weighted distance process

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 3737

Cost Distance or Path DistanceCost Distance or Path Distance

AllocationAllocationBack linkBack link

Model cost surface

Model cost surface

Create sourcesCreate sources

Create destinations

Create destinations

Cost PathCost Path

PathsPaths

Page 39: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Creating the cost surfaceCreating the cost surface

•• Cost to travel through each cellCost to travel through each cell–– High values = high travel costHigh values = high travel cost

•• Express as costExpress as cost--perper--unit distanceunit distance–– Dollars per foot, hours per meter, and so Dollars per foot, hours per meter, and so

onon•• Create by modelingCreate by modeling

–– Often considers many variablesOften considers many variables

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 3838

SlopeSoil typeVegetationdensity

Roads and trails

Landslidezones

Travel costsurface

Cross-country mobility model

Page 40: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Calculating travel costsCalculating travel costs

•• Calculating cellCalculating cell--toto--cell travel costcell travel cost

•• The process spreads from sourcesThe process spreads from sources–– Start at a source cellStart at a source cell–– Find cost to each neighborFind cost to each neighbor–– Move to cheapest neighborMove to cheapest neighbor–– Find cost to each neighborFind cost to each neighbor–– Repeat until all cells are reachedRepeat until all cells are reached

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 3939

SSSSS

A

21 CostBCostACellsizeCostAB +××=

22 CostCCostACellsizeCostAC +××= B

C

A

Page 41: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Accumulated travel cost outputAccumulated travel cost output

•• Cost accumulates away from source cellsCost accumulates away from source cells–– High values = Higher cost to travelHigh values = Higher cost to travel

•• Use asUse as–– A measure of accessibilityA measure of accessibility–– An input to Cost PathAn input to Cost Path

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 4040

Accumulated travel cost Accumulated travel cost

Page 42: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Back link outputBack link output

•• Direction codes point back to the nearest sourceDirection codes point back to the nearest source–– For each cell, points to the adjacent cell on leastFor each cell, points to the adjacent cell on least--cost pathcost path

•• Required by the Cost Path toolRequired by the Cost Path tool

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 4141

6 7 8

5 0 1

4 3 2

Backlink codesBacklink codes

Backlink rasterBacklink raster

Page 43: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Finding pathsFinding paths

•• Finds leastFinds least--cost paths from cost paths from sources to destinationssources to destinations

–– User interface = line featuresUser interface = line features–– COSTPATH = raster lines COSTPATH = raster lines

(with attributes)(with attributes)•• Required inputsRequired inputs

–– DestinationsDestinations–– COSTDISTANCE outputsCOSTDISTANCE outputs

•• Accumulated travel cost gridAccumulated travel cost grid•• Direction gridDirection grid

•• Shortest Path in user Shortest Path in user interfaceinterfaceor COSTPATH functionor COSTPATH function

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 4242

Source

DestinationLeast-cost path

Shared path

Page 44: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

OverviewOverview

•• Introduction to ArcGIS Spatial AnalystIntroduction to ArcGIS Spatial Analyst–– What is Spatial AnalystWhat is Spatial Analyst–– Why use raster dataWhy use raster data–– What is raster dataWhat is raster data

•• Accessing Spatial Analyst capabilitiesAccessing Spatial Analyst capabilities–– The seven interfacesThe seven interfaces–– Environment setting optionsEnvironment setting options

•• Basic Spatial Analyst ConceptsBasic Spatial Analyst Concepts–– The language of raster analysisThe language of raster analysis–– Spatial Analyst functionsSpatial Analyst functions

•• Modeling Modeling –– What are modelsWhat are models–– Types of modelsTypes of models

•• Calculating riskCalculating risk•• QuestionsQuestions

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 4343

Page 45: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

What is a model?What is a model?

•• A representation of realityA representation of reality–– Model airplaneModel airplane–– DollhouseDollhouse–– Video gameVideo game–– Risk surfaceRisk surface

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 4444

Onions

Chop

BoilWhole Chicken

Celery CarrotsWild Rice

Chopped Vegetables

Chicken Broth

Garlic

Chicken Soup

Salt and

Pepper

Boil

Chicken Boiled Separate Chicken

Bones

Chicken Meat

Page 46: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Why use models?Why use models?

•• Share process with othersShare process with others•• Document workDocument work•• Solve simple or complex Solve simple or complex

problemsproblems•• Modify variables easilyModify variables easily

–– Rerun Rerun –– Explore what if scenariosExplore what if scenarios

•• Framework for Framework for understanding realunderstanding real--world world processesprocesses

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 4545

Select

Select

Buffer

Buffer

Forest Areas

Good View

Distance to Lakes

Distance to Trail

View

Lakes

Trails

Landcover

Intersect Natural Setting

Page 47: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Types of modelsTypes of models

Representation models

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 4646

Filling a reservoirBest Shelter location

GIS data layers

Suitability models Process models

Automated workflowsRepresentation models

Page 48: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Suitability: Binary modelsSuitability: Binary models

•• Use for simple problemsUse for simple problems•• Classify layers into good (1) and bad (0)Classify layers into good (1) and bad (0)

–– Combine with AND, addition, or multiplication Combine with AND, addition, or multiplication EOC = Road And Access And View

•• AdvantagesAdvantages–– EasyEasy

•• DisadvantagesDisadvantages–– No nextNo next--best sites best sites –– All layers have same importanceAll layers have same importance–– All good values have same importanceAll good values have same importance

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 4747

Access

View

EOC

Road

10

00

1

0 01

00 1

Page 49: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Suitability: Weighted modelsSuitability: Weighted models

•• Use for complex problemsUse for complex problems•• Classify layers into suitability 1 Classify layers into suitability 1 –– 9 (9 = best)9 (9 = best)

–– Weight each layerWeight each layerEOC = (Road * 0.5)

+ (Access * 0.3) + (View * 0.2)

•• Advantages:Advantages:–– All values have relative importanceAll values have relative importance–– All layers have relative importanceAll layers have relative importance–– Returns suitability on a scale 1 Returns suitability on a scale 1 –– 99

•• Disadvantages:Disadvantages:–– Preference assessment is harderPreference assessment is harder

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 4848

951

View

EOC

96.6

7.01.8

5.04.2

951

Access

95

1Road

Page 50: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Suitability: Data typesSuitability: Data types

•• The type of data is importantThe type of data is important•• Data typesData types

–– NominalNominal–– OrdinalOrdinal–– IntervalInterval–– RatioRatio

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 4949

12

3

6

9100

25

50

75

FinishedRunner

Time of dayElapsed time

OrdinalNominal

IntervalRatio

3rd#72 – Tom

4:05:0981 sec

2nd#43 – Sam

4:05:0779 sec

1st#10 – Joe

4:05:0375 sec

TomSam Joe

Page 51: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Suitability: Factors that influence modelsSuitability: Factors that influence models

•• Scale of suitabilityScale of suitability–– Use the same scale for all layersUse the same scale for all layers–– Map values using the scaleMap values using the scale

•• Model calibrationModel calibration–– Tune to produce accurate resultsTune to produce accurate results–– Three main sources of errorThree main sources of error

•• Omitting important layersOmitting important layers•• Incorrect methods Incorrect methods •• Errors in weightsErrors in weights

•• Sensitivity analysisSensitivity analysis–– Determine the importance of each layerDetermine the importance of each layer

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 5050

Value priority

8 High7 High minus6 Moderate plus5 Moderate4 Moderate minus3 Low plus2 Low

9 High plus

1 Low minus

Best

Worst

Page 52: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Reclassify toolReclassify tool

•• Can use to convert measures to suitabilityCan use to convert measures to suitability

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 5151

Page 53: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Reclassifying with equationsReclassifying with equations

•• An option with ratio dataAn option with ratio data–– Need a mathematical relationship between data and suitabilityNeed a mathematical relationship between data and suitability

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 5252

• Set suitability = 0where [RoadDist] = 5000

• Solve for line slope: -0.0018

• Set suitability = 0where [RoadDist] = 5000

• Solve for line slope: -0.0018

123456789

00 5,000

Distanceto road

Suitability

y-intercept

x-intercept

Slope of the line

Example: Suitability decreases with distance to roads

RoadSuit = 9 + ( -0.0018 ∗ RoadDist )Implement with Map Algebra or a model:

Page 54: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Weighting and combining the layersWeighting and combining the layers

•• For each submodelFor each submodel–– Multiply suitability layers by weightsMultiply suitability layers by weights

•• Weights must add up to oneWeights must add up to one–– Add the weighted layers togetherAdd the weighted layers together

•• Repeat to combine submodelsRepeat to combine submodels•• Uses one Map Algebra expressionUses one Map Algebra expression

per submodelper submodel•• Use the Weighted Overlay toolUse the Weighted Overlay tool

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 5353

951

View

EOC

96.6

7.01.8

5.04.2

951

Access

95

1Road

EOC = (Road * .5) + (Access * .3) + (View * .2)

Page 55: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

Weighted Overlay toolWeighted Overlay tool

•• Weights and combines multiple inputsWeights and combines multiple inputs

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 5454

Page 56: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

OverviewOverview

•• Introduction to ArcGIS Spatial AnalystIntroduction to ArcGIS Spatial Analyst–– What is Spatial AnalystWhat is Spatial Analyst–– Why use raster dataWhy use raster data–– What is raster dataWhat is raster data

•• Accessing Spatial Analyst capabilitiesAccessing Spatial Analyst capabilities–– The seven interfacesThe seven interfaces–– Environment setting optionsEnvironment setting options

•• Basic Spatial Analyst ConceptsBasic Spatial Analyst Concepts–– The language of raster analysisThe language of raster analysis–– Spatial Analyst functionsSpatial Analyst functions

•• Modeling Modeling –– What are modelsWhat are models–– Types of modelsTypes of models

•• Calculating riskCalculating risk•• QuestionsQuestions

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 5555

Page 57: Spatial Analyst for Geospatial Intelligence - Amazon S3 · Spatial Analyst for Geospatial Intelligence ... 112 12 2222 2 22 222 2 222 22 2222 221 22 2211 2 11 1ND1 1 333 34 ... (IDW,

QuestionsQuestions

FedUC 2009 Technical WorkshopsFedUC 2009 Technical Workshops 5656

Thank you !!Thank you !!