Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each...

22
2/20/2015 1 Longley Chapter 3 Digital Geographic Data Representation Geographic Data Type Data Models Representing Spatial and Temporal Data Attributes The Nature of Geographic Data Representations Are needed to convey information Fit information into a standard form or model In the diagram the colored trajectories consist only of a few straight lines connecting points Almost always simplify the truth that is being represented There is no information in the representation about daily journeys to work and shop, or vacation trips out of town

Transcript of Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each...

Page 1: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

1

Longley Chapter 3

Digital Geographic Data RepresentationGeographic Data TypeData ModelsRepresenting Spatial and Temporal Data AttributesThe Nature of Geographic Data

Representations

• Are needed to convey information

• Fit information into a standard form or model

– In the diagram the colored trajectories consist only of a few straight lines connecting points

• Almost always simplify the truth that is being represented

– There is no information in the representation about daily journeys to work and shop, or vacation trips out of town

Page 2: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

2

Representations Occur:

• In the human mind, when information is acquired through the senses and stored in memory

• In photographs, which are two‐dimensional models of light received by the camera

• In written text, when information is expressed in words

Digital Representation

• Uses only two symbols, 0 and 1, to represent information

• The basis of almost all modern human communication

• Many standards allow various types of information to be expressed in digital form– MP3 for music

– JPEG for images

– ASCII for text

– GIS relies on standards for geographic data

Page 3: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

3

Why Digital?

• Economies of scale– One type of information technology for all types of information

• Simplicity

• Reliability– Systems can be designed to correct errors

• Easily copied and transmitted– At close to the speed of light

Accuracy of Representations

• Representations can rarely be perfect

– Details can be irrelevant, or too expensive and voluminous to record

• It’s important to know what is missing in a representation

– Representations can leave us uncertain about the real world

Page 4: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

4

The Fundamental Problem

• Geographic information links a place, and often a time, with some property of that place (and time)– “The temperature at 34 N, 120 W at noon local 

time on 12/2/99 was 18 Celsius”

Schematic representation of the lives of threeUS citizens in space (two horizontal axes) andtime (vertical axis)

The potential number of properties is vast

In GIS we term them attributes

Attributes can be physical, social, economic, demographic, environmental, etc.

Types of Attributes

• Nominal, e.g. land cover class

• Ordinal, e.g. a ranking

• Interval, e.g. Celsius temperature– Differences make sense

• Ratio, e.g. Kelvin temperature– Ratios make sense

• Cyclic, e.g. wind direction

Page 5: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

5

Cyclic Attributes

• Do not behave as other attributes– What is the average of two compass bearings, e.g. 350 and 10?

• Occur commonly in GIS– Wind direction

– Slope aspect

– Flow direction

• Special methods are needed to handle and analyze

The Fundamental Problem (cont.)

• The number of places and times is also vast– Potentially infinite

• The more closely we look at the world, the more detail it reveals– Potentially ad infinitum

– The geographic world is infinitely complex

• Humans have found ingenious ways of dealing with this problem– Many methods are used in GIS to create representations or data models

– Spatial Data Types are represented with Data Models

Page 6: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

6

Spatial Data Types

• continuous: elevation, rainfall, soil type

• areas (polygons):– unbounded: landuse, market areas, soils, rock type

– bounded: city/county/state boundaries, ownership parcels, zoning

– moving: air masses, animal herds, schools of fish

• networks (lines):– roads, transmission lines, streams

• points:– fixed: wells, fire hydrants, trees, addresses

– moving: cars, wolves, birds

Discrete Objects and Continuous Fields

• These are the two ways of conceptualizing geographic variation– The most fundamental distinction in geographic representation

– Discrete objects, or data that represents phenomenon with well‐defined boundaries

– Continuous fields, or data that represents variation of value of a theme consistently and continuously over space

Page 7: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

7

Discrete Objects

• Characteristics of Discrete Objects:

– Points, lines, and areas

– Countable

– Persistent through time, perhaps mobile

– Biological organisms

• Animals, trees

– Human‐made objects

• Vehicles, houses, fire hydrants

Continuous Fields

• Characteristics of continuous fields:

– Properties that vary continuously over space

• Value is a function of location

• Property can be of any attribute type, including direction

– Elevation as the archetypical example:

• A single value at every point on the Earth’s surface

• The source of metaphor and language– Any field can have slope, gradient, peaks, pits

Page 8: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

8

Examples of Fields

• Soil properties, e.g. pH, soil moisture

• Population density– But at fine enough scale the concept breaks down

• Identity of land owner– A single value of a nominal property at any point

• Name of county or state or nation

• Atmospheric temperature, pressure

Difficult Cases

• Lakes and other natural phenomena– Often conceived as objects, but difficult 

to define or count precisely

• Weather forecasting– Forecasts originate in models of fields, 

but are presented in terms of discrete objects

• Highs, lows, fronts

Page 9: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

9

How Do We Represent These Data Types in a GIS? 

• The Raster and Vector data models…

Rasters and Vectors

• How to represent phenomena conceived as fields or discrete objects?

• Raster– Divide the world into square cells

– Register the corners to the Earth

– Represent discrete objects as collections of one or more cells

– Represent fields by assigning attribute values to cells

– More commonly used to represent fields than discrete objects

Page 10: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

10

0 1 2 3 4 5 6 7 8 90 R T1 R T2 H R3 R4 R R5 R6 R T T H7 R T T8 R9 R

Real World

Vector RepresentationRaster Representation

Concept of Vector and Raster

line

polygon

point

Characteristics of Rasters

• Pixel size– The size of the cell or picture element, defining the level of spatial detail

– All variation within pixels is lost

• Assignment scheme– The value of a cell may be an average over the cell, or a total within the cell, or the commonest value in the cell

– It may also be the value found at the cell’s central point

Page 11: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

11

Legend

Mixed conifer

Douglas fir

Oak savannah

Grassland

Each color represents a different value of a nominal-scale field denoting land cover class

Raster representation

Representing Data using RasterModel

• Area is covered by grid (usually) with equal‐sized cells

• Location ‐ of each cell calculated from origin of grid: “two down, three over” – (usually from upper left, but lower left in ARCVIEW)

• Called raster cells or pixels (picture elements) – raster data often called image data 

• Attributes ‐ are recorded by assigning each cell a single value based on the majority feature (attribute) in the cell, such as land use type

0 1 2 3 4 5 6 7 8 90 1 1 1 1 1 4 4 5 5 51 1 1 1 1 1 4 4 5 5 52 1 1 1 1 1 4 4 5 5 53 1 1 1 1 1 4 4 5 5 54 1 1 1 1 1 4 4 5 5 55 2 2 2 2 2 2 2 3 3 36 2 2 2 2 2 2 2 3 3 37 2 2 2 2 2 2 2 3 3 38 2 2 4 4 2 2 2 3 3 39 2 2 4 4 2 2 2 3 3 3

commercial

industrial

Res. pub

lic

Res.

Page 12: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

12

1

1

2

3

4

5

6

7

8

9

10

1 2 3 4 5 6 7 8 9 100

X

Y

Representing Data using RasterModel

• Easy to do overlays/analyses, just by ‘combining’ corresponding cell values: – “crime index” = juvenile + adult crime rate

• (I think it’s potentially improper…)

• why raster is faster, at least for some things

• Simple data structure:– directly store each layer as a single table 

• analogous to a “spreadsheet”)

– no computer database‐management‐system (DBMS) required• although GIS systems incorporate them

commercial

industrial

Res. pub

lic

Res.

Page 13: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

13

1

1

2

3

4

5

6

7

8

9

10

1 2 3 4 5 6 7 8 9 100

X

Y

Page 14: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

14

Legend

Mixed conifer

Douglas fir

Oak savannah

Grassland

Each color represents a different value of a nominal-scale field denoting land cover class

Raster representation

Page 15: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

15

Raster Data Sets:

• Data – Landsat TM(1992) & ETM+ (2002)

10/02/1992 10/06/2002

17/32 17/32

Classified Data:

Page 16: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

16

Vector Data

• Used to represent points, lines, and areas

• All are represented using coordinates

– One per point

– Areas as polygons• Straight lines between points, connecting back to the start

• Point locations recorded as coordinates

– Lines as polylines• Straight lines between points

Representing Data using the VectorModel: General concept

The fundamental concept of vector GIS is that all geographic features on the earth’s surface (or on a map) can be represented either as:

– points (no area): trees, sample locations, crime locations, rocks, manhole covers

– lines (arcs): streets, sidewalks, transmission lines, streams

– areas (polygons): cities, counties, buildings, states, ponds and lakes, land uses, land covers

• Which is used in a particular instance depends on scale, among other things: 

– for example – Leonard Hall may be a point or polygon

• Because representation depends on shape, ArcView refers to files containing spatial data as shapefiles.

Page 17: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

17

1

Representing Data using the VectorModel:

• Point  (node): 0‐dimension– one x,y coordinate pair

– zero area

– tree, oil well, label  location 

• Line  (arc): 1‐dimension– two (or more)  connected  x,y

coordinates

– road, stream

• Polygon : 2‐dimensions– four or more ordered and connected 

x,y coordinates 

– first and last x,y pairs are the same

– encloses an area

– census tracts, county, lake 

1

2

7 8

x=7

Point: 7,2y=2

Line: 7,2 / 8,1

Polygon: 7,2 / 8,1 / 7,1 / 7,2

1

2

7 8

1

2

7 8

1

2

7 8

Attribute data on the right are linked to spatial data by the label ID of map features

Page 18: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

18

Representing Data using the VectorModel:Data implementation

Coordinates TablePoint ID x y

1 1 32 2 13 4 14 1 25 3 2

1

2 3

4 5

X

YCommon identifiers provide link to:

coordinates table (for where)

attributes table (for what or when)

Point ID Crime time1 robbery 9:302 assault 11:303 drug 5:004 robbery 2:305 b & e 3:00

Concepts are those of a relational data base, which is really a prerequisite for the vector model (or need object-oriented computing environment)

Features in the theme (coverage) have unique identifiers--point ID, polygon ID, arc ID, etcUsually referred to as the Feature ID (FID)

(Vector) Topology: What is it?Programmed rules in GISs like ArcGIS that establish spatial relationships 

between features (points, lines, polygons)

• Spatial Relationships– each arc has a beginning and 

ending node

– arcs connect to other arcs at nodes

– connected arcs form polygon boundaries

– arcs have polygons on their left and right

– containment

• Spatial Properties– length, directionality of arc

– connectivity

– area, perimeter of polygons

– adjacency or contiguity

– point or line ‐in‐polygon

Page 19: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

19

The Vector Data Model: Topological vs. Non‐topological Spatial Data

• Topological Vector Data – contains data regarding the (spatial) relationships between features

– Ex. ArcGIS coverages, geodatabases

• Non‐topological – no data regarding spatial relationships is recorded or stored

– Ex. ArcGIS shapefiles

The data structure of a point data model

Point (node): 0-dimension• single x,y coordinate pair• zero area(Example: tree, oil well, label location)

(0,0)

3 (2,2)

2 (4,4)

4 (6,2)

1 (2,9)

ID X,Y

1 2,9

2 4,4

3 2,2

4 6,2

Point List

X

Y

Page 20: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

20

The data structure of a line data model

Line (arc): 2-dimension• From Nodes (points) – T Nodes (points)•x,y coordinate pair(s) depend # of Nodes and vertices• zero area(Example: tree, oil well, label location)

The data structure of an area (polygon) data model

Page 21: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

21

GIS  Data Models:   Raster vs. Vector

• Raster data model

– location is referenced by a grid cell in a rectangular array

– attribute is represented as a single value for that cell

– many data comes in  this form 

• images from remote sensing (LANDSAT, SPOT, QuickBird)

• scanned maps

• elevation data from USGS

– best for continuous features:

• elevation

• temperature

• soil type

• land use

• Vector data model– location referenced by x,y,z

coordinates, which can be linked to form lines and polygons

– attributes referenced through unique ID number to tables

– many data comes in this form• DIME and TIGER files from US 

Census

• DLG from USGS for streams, roads, etc

• census data (tabular)

– best for features with discrete boundaries

• property lines

• political boundaries

• transportation

Raster vs Vector

• Volume of data

– Raster becomes more voluminous as cell size decreases

• Source of data

– Remote sensing, elevation data come in raster form

– Vector favored for administrative data

• Software

– Some GIS used to be better suited to raster, some to vector, now all handle both

Page 22: Longley Chapter 3 · between features (points, lines, polygons) • Spatial Relationships – each arc has a beginning and ending node – arcs connect to other arcs at nodes –

2/20/2015

22

The GIS Model: example

Here we have multiple layers:--vegetation --soil--hydrology

They can be related because precise geographic coordinates are recorded for each layer.

longitude

Layers may be represented in two ways:•in vector format as lines•in raster(image) format as pixels