anisotropy.plot(formula=formula(data), data=sys.parent(), subset, na.action, lag=<<see below>>, nlag=20, tol.lag=lag/2, maxdist=<<see below>>, angle=c(0, 45, 90, 135), ratio=seq(1.25, 2, length = 4), minpairs=6, method="classical", smooth=T, plot.it=T, panel=panel.xyplot, ...)
z ~ x + y
z
variable is a numeric response.
Variables
x
and
y
are the locations.
All variables in the formula must be vectors of equal length
with no missing values (
NA
s).
The formula may also contain expressions for the variables, for example,
sqrt(count)
,
log(age+1)
or
I(2*x)
.
(The
I()
is required since the
*
operator has a special meaning
on the right side of a formula.)
formula
.
model.frame
after
any
subset
argument has been used.
The default (with
na.fail
) is to create an error
if any missing values are found.
A possible alternative is
na.omit
,
which deletes observations that contain one or more missing values.
lag
is set
to
maxdist / nlag
.
np
)
that must be used in calculating a variogram value.
If
np
is less
than
minpairs
,
that value is dropped from the variogram.
"classical"
for Matheron's (1963) estimate
and
"robust"
for Cressie and Hawkin's (1980)
robust estimator.
Only the first character of the string needs to be given.
TRUE
,
a loess smooth line is drawn for each variogram panel.
If
panel
is supplied then this value is ignored.
plot.it=FALSE
, this value is ignored.
TRUE
,
a plot of all the variogram is drawn.
plot.it=TRUE
(the default)
the variogram for each combination
of
angle
and
ratio
is plotted.
The plot is drawn using
xyplot
.
For each combination of
angle
and
ratio
the locations are corrected
for geometric anisotropy.
The correction consists of multipling each location pair
(
x[i]
,
y[i]
)
by the symmetric 2 x 2 matrix
A
where
A[1,1]
=
cos(angle)^2+ratio*sin(angle)^2
,
A[1,2]
=
(1- ratio) * sin(angle) * cos(angle)
and
A[2,2]
=
sin(angle)^2+ratio*cos(angle)^2
.
See Journel and Huijbregts (1978, pp 179-181).
The variogram is then estimated using these corrected locations.
Cressie, N. and Hawkins, D. M. (1980). Robust estimation of the variogram. Mathematical Geology 12, 115-125.
Journel, A. G. and Huijbregts, Ch. J. (1978). Mining Geostatistics. Academic Press, New York.
Matheron, G. (1963). Principles of geostatistics. Economic Geology 58, 1246-1266.
anisotropy.plot(log(tcatch+1) ~ long + lat, data=scallops, lag=.075)