hopskel {spatstat.explore} | R Documentation |
Hopkins-Skellam Test
Description
Perform the Hopkins-Skellam test of Complete Spatial Randomness, or simply calculate the test statistic.
Usage
hopskel(X)
hopskel.test(X, ...,
alternative=c("two.sided", "less", "greater",
"clustered", "regular"),
method=c("asymptotic", "MonteCarlo"),
nsim=999)
Arguments
X |
Point pattern (object of class |
alternative |
String indicating the type of alternative for the hypothesis test. Partially matched. |
method |
Method of performing the test. Partially matched. |
nsim |
Number of Monte Carlo simulations to perform, if a Monte Carlo p-value is required. |
... |
Ignored. |
Details
Hopkins and Skellam (1954) proposed a test of Complete Spatial Randomness based on comparing nearest-neighbour distances with point-event distances.
If the point pattern X
contains n
points, we first compute the nearest-neighbour distances
so that
is the distance from the
th data
point to the nearest other data point. Then we
generate another completely random pattern
U
with
the same number n
of points, and compute for each point of U
the distance to the nearest point of X
, giving
distances .
The test statistic is
The null distribution of is roughly
an
distribution with shape parameters
.
(This is equivalent to using the test statistic
and referring
to the Beta distribution with parameters
).
The function hopskel
calculates the Hopkins-Skellam test statistic
, and returns its numeric value. This can be used as a simple
summary of spatial pattern: the value
is consistent
with Complete Spatial Randomness, while values
are
consistent with spatial clustering, and values
are consistent
with spatial regularity.
The function hopskel.test
performs the test.
If method="asymptotic"
(the default), the test statistic
is referred to the
distribution. If
method="MonteCarlo"
,
a Monte Carlo test is performed using nsim
simulated point
patterns.
Value
The value of hopskel
is a single number.
The value of hopskel.test
is an object of class "htest"
representing the outcome of the test. It can be printed.
Author(s)
Adrian Baddeley Adrian.Baddeley@curtin.edu.au, Rolf Turner rolfturner@posteo.net and Ege Rubak rubak@math.aau.dk.
References
Hopkins, B. and Skellam, J.G. (1954) A new method of determining the type of distribution of plant individuals. Annals of Botany 18, 213–227.
See Also
clarkevans
,
clarkevans.test
,
nndist
,
nncross
Examples
hopskel(redwood)
hopskel.test(redwood, alternative="clustered")