For a multitype point pattern, estimate the multitype J function summarising the interpoint dependence between the type i points and the points of any type.
The observed point pattern, from which an estimate of the multitype J function Ji.(r) will be computed. It must be a multitype point pattern (a marked point pattern whose marks are a factor). See under Details.
The type (mark value)
of the points in
A positive number. The resolution of the discrete approximation to Euclidean distance (see below). There is a sensible default.
numeric vector. The values of the argument r at which the function Ji.(r) should be evaluated. There is a sensible default. First-time users are strongly advised not to specify this argument. See below for important conditions on r.
This argument is for internal use only.
Optional. Character string specifying the edge correction(s)
to be used. Options are
Jdot and its companions
are generalisations of the function
to multitype point patterns.
A multitype point pattern is a spatial pattern of points classified into a finite number of possible “colours” or “types”. In the spatstat package, a multitype pattern is represented as a single point pattern object in which the points carry marks, and the mark value attached to each point determines the type of that point.
X must be a point pattern (object of class
"ppp") or any data that are acceptable to
It must be a marked point pattern, and the mark vector
X$marks must be a factor.
i will be interpreted as a
level of the factor
X$marks. (Warning: this means that
an integer value
i=3 will be interpreted as the number 3,
not the 3rd smallest level.)
The “type i to any type” multitype J function of a stationary multitype point process X was introduced by Van lieshout and Baddeley (1999). It is defined by
Ji.(r) = (1 - Gi.(r))/(1-F.(r))
where Gi.(r) is the distribution function of the distance from a type i point to the nearest other point of the pattern, and F.(r) is the distribution function of the distance from a fixed point in space to the nearest point of the pattern.
An estimate of Ji.(r)
is a useful summary statistic in exploratory data analysis
of a multitype point pattern. If the pattern is
a marked Poisson point process, then
Ji.(r) = 1.
If the subprocess of type i points is independent
of the subprocess of points of all types not equal to i,
then Ji.(r) equals
Jii(r), the ordinary J function
Jest and Van Lieshout and Baddeley (1996))
of the points of type i.
Hence deviations from zero of the empirical estimate of
may suggest dependence between types.
This algorithm estimates Ji.(r)
from the point pattern
X. It assumes that
X can be treated
as a realisation of a stationary (spatially homogeneous)
random spatial point process in the plane, observed through
a bounded window.
The window (which is specified in
may have arbitrary shape.
Biases due to edge effects are
treated in the same manner as in
using the Kaplan-Meier and border corrections.
The main work is done by
r is the vector of values for the
distance r at which Ji.(r) should be evaluated.
The values of r must be increasing nonnegative numbers
and the maximum r value must exceed the radius of the
largest disc contained in the window.
An object of class
Essentially a data frame containing six numeric columns
the recommended estimator of Ji.(r), currently the Kaplan-Meier estimator.
the values of the argument r at which the function Ji.(r) has been estimated
the Kaplan-Meier estimator of Ji.(r)
the “reduced sample” or “border correction” estimator of Ji.(r)
the Hanisch-style estimator of Ji.(r)
estimator of Ji.(r)
formed by taking the ratio of uncorrected empirical estimators
of 1 - Gi.(r)
and 1 - F.(r), see
the theoretical value of Ji.(r) for a marked Poisson process, namely 1.
The result also has two attributes
which are respectively the outputs of
Fest for the point pattern.
i is interpreted as
a level of the factor
X$marks. It is converted to a character
string if it is not already a character string.
i=1 does not
refer to the first level of the factor.
Van Lieshout, M.N.M. and Baddeley, A.J. (1996) A nonparametric measure of spatial interaction in point patterns. Statistica Neerlandica 50, 344–361.
Van Lieshout, M.N.M. and Baddeley, A.J. (1999) Indices of dependence between types in multivariate point patterns. Scandinavian Journal of Statistics 26, 511–532.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
# Lansing woods data: 6 types of trees woods <- lansing Jh. <- Jdot(woods, "hickory") plot(Jh.) # diagnostic plot for independence between hickories and other trees Jhh <- Jest(split(woods)$hickory) plot(Jhh, add=TRUE, legendpos="bottom") ## Not run: # synthetic example with two marks "a" and "b" pp <- runifpoint(30) %mark% factor(sample(c("a","b"), 30, replace=TRUE)) J <- Jdot(pp, "a") ## End(Not run)
Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.