Spatial Interpolation
Spatial Interpolation
Interpolation
• Works under the principle of the
continuous field data model
• Interpolation is not normally a good idea
when dealing with the object data model
(how does one interpolate a cow?)
– Could interpolate a density surface, but this
then falls under the field data model.
1
Example interpolation types
• Nearest Neighbour
– Take value of nearest sample
• Trend surface (global)
– Fit a function to the data (Z = f(X,Y))
• Inverse Distance Weighted
– Weights defined by power functions (1/d, 1/d2,
1/d3,…)
• Splines
– Smooth curves
• Kriging
– Quantify form of spatial relationship using the data
2
5m contour interval.
Digitised from
1:10,000 scale ACT
planning series.
3
Nearest Neighbour
4
Nearest Neighbour (zoom)
Trend Surfaces
5
IDW weights
1.4
1.2
1
Power 1
0.8 Power 2
Power 3
0.6 Power 4
0.4
0.2
0
-12 -7 -2 3 8
IDW
Power 1 Power 3
6
Channels from IDW
Flow Accumulation
> 100 cells
Black = Order 1
Red = Order 3
A Potentially Undesirable
Characteristic of IDW interpolation
This set of six data
points clearly suggests
a hill profile (dashed
line). But in areas
where there is little or
no data the interpolator
will move towards the
overall mean (solid
line).
7
Splines (regularised)
Surface Channels
ANUDEM algorithm
• Spline interpolator
• Enforces drainage patterns into the DEM
– Introduces process knowledge into the
interpolation
• Maintains hydrologic connectivity
– Clear artificial sinks
• Used for DEM of Australia
8
ANUDEM
9
Other interpolation artefacts:
land surface curvature
10
Three methods in Arc GIS
•IDW
•SPLINE
•Kriging
11
Inverse Distance Weighting
•IDW: assumes value of an attribute z at any unsampled
point is a distance-weighted average of sampled points
lying within a defined neighborhood around that
unsampled point. Essentially it is a weighted moving avg
^ n
z ( x0 ) = ∑ λi ⋅ z ( xi )
n
-p
•Common form of weighting function is d yielding:
n
^ ∑ z ( x i ) ⋅ d ij− p
z ( x0 ) = i =1
n
∑d
i =1
−p
ij
IDW-How it works
•Z value at location ij is f of Z value
at known point xy times the inverse
distance raised to a power P.
•Z value field: numeric attribute to be
interpolated
•Power: determines relationship of
weighting and distance; where p= 0,
no decrease in influence with
distance; as p increases distant points
becoming less influential in
interpolating Z value at a given pixel
12
IDW-How it works
•What is the best P to use?
•It is the P where the Root Mean Squared
Prediction Error (RMSPE) is lowest, as
in the graph on right
•To determine this, we would need a test,
or validation data set, showing Z values
in x,y locations that are not included in
prediction data and then look for
discrepancies between actual and
predicted values. We keep changing the
P value until we get the minimum level
of error. Without this, we just guess.
Spline Method
•Another option for interpolation method
•This fits a curve through the sample data assign values to
other locations based on their location on the curve
•Thin plate splines create a surface that passes through sample
points with the least possible change in slope at all points,
that is with a minimum curvature surface.
•Uses piece-wise functions fitted to a small number of data
points, but joins are continuous, hence can modify one part of
curve without having to recompute whole
•Overall function is continuous with continuous first and
second derivatives.
13
Spline Method
•SPLINE has two types: regularized and tension
•Tension results in a rougher surface that more closely
adheres to abrupt changes in sample points
•Regularized results in a smoother surface that smoothes out
abruptly changing values somewhat
Spline Method
•Weight: this controls the tautness of the curves.
High weight value with the Regularized Type, will
result in an increasingly smooth output surface.
Under the Tension Type, increases in the Weight
will cause the surface to become stiffer, eventually
conforming closely to the input points.
•Number of points around a cell that will be used to
fit a polynomial function to a curve
14
Pros and Cons of Spline
Method
•Splines retain smaller features, in
contrast to IDW
•Produce clear overview of data
•Continuous, so easy to calculate
derivates for topology
•Results are sensitive to locations of
break points
•No estimate of errors, like with IDW
•Can often result in over-smooth surfaces
Kriging Method
•Like IDW interpolation, Kriging forms weights from surrounding
measured values to predict values at unmeasured locations. As with
IDW interpolation, the closest measured values usually have the
most influence. However, the kriging weights for the surrounding
measured points are more sophisticated than those of IDW. IDW
uses a simple algorithm based on distance, but kriging weights
come from a semivariogram that was developed by looking at the
spatial structure of the data. To create a continuous surface or map
of the phenomenon, predictions are made for locations in the study
area based on the semivariogram and the spatial arrangement of
measured values that are nearby.
--from ESRI Help
15
Kriging Method
•Kriging is a geostatistical method and a probabilistic method,
unlike the others, which are deterministic. That is, there is a
probability associated with each prediction. Kriging has both a
deterministic and probabilistic component, respectively
Z(s) = µ(s) + ε(s), where both are functions of distance
•Assumes spatial variation in variable is too irregular to be modeled
by simple smooth function, better with stochastic surface
•Interpolation parameters (e.g. weights) are chosen to optimize fn
•Assumes that variable in space can be modeled as sum of three
components: 1) structure/deterministic part, 2) random but spatially
correlated part and 3) spatially uncorrelated random part
Kriging Method
•Hence, foundation of Kriging is notion of spatial autocorrelation,
or tendency of values of entities closer in space to be related.
•This is a violation of classical statistical models, since
observations are assumed to be independent.
•Autocorrelation can be assessed using a semivariogram, which
plots the difference in pair values (variance) against their distances.
16
Kriging Method
•Semivariogram(distance h) = 0.5 * average [ (value at location i–
value at location j)2] OR
n
∧ ∑{z( x ) − z( x + h)}
i i
2
γ (h) = i =1
2n
•Based on the scatter of points, the computer (Geostatistical analyst)
fits a curve through those points
•The inverse is the covariance matrix which
shows correlation over space
Kriging Method
•We can then use a scatter plot of predicted versus actual values to
see the extent to which our model actually predicts the values
•If the blue line and the points lie along the 1:1 line this indicates
that the kriging model predicts the data well
17
Kriging Method
•The fitted variogram results in a series of matrices and vectors that
are used in weighting and locally solving the kriging equation.
•Basically, at this point, it is similar to other interpolation methods
in that we are taking a weighting moving average, but the weights
(λ) are based on statistically derived∧ autocorrelation measures.
z ( x0 )
• λs are chosen so that the estimate is unbiased and the
estimated variance is less than for any other possible linear combo
of the variables.
Kriging Method
•Produces four types of prediction maps:
•Prediction Map: Predicted values
•Probability Map: Probability that value over x
•Prediction Standard Error Map: fit of model
•Quantile maps: Probability that value over certain quantile
18
Kriging Method
•Semivariograms measure the strength of statistical correlation as a
function of distance; they quantify spatial autocorrelation
•Because Kriging is based on the semivariogram, it is probabilistic,
while IDW and Spline are deterministic
•Kriging associates some probability with each prediction, hence it
provides not just a surface, but some measure of the accuracy of
that surface
•Kriging equations are determined by fitting line through points so
as to minimize weighted sum of squares between points and line
•These equations are weighted based on spatial autocorrelation,
which is determined from the semivariograms
Example
•Here are some sample elevation points from which surfaces were
derived using the three methods
19
Example: IDW
•Done with P =2. Notice how it is not as smooth as Spline. This is
because of the weighting function introduced through P
Example: Spline
•Note how smooth the curves of the terrain are; this is because
Spline is fitting a simply polynomial equation through the points
20
Example: Kriging
•This one is kind of in between—because it fits an equation
through point, but weights it based on probabilities
21