# Jcross

0th

Percentile

##### Multitype J Function (i-to-j)

For a multitype point pattern, estimate the multitype $J$ function summarising the interpoint dependence between points of type $i$ and of type $j$.

Keywords
spatial, nonparametric
##### Usage
Jcross(X, i, j, eps=NULL, r=NULL, breaks=NULL, ..., correction=NULL)
##### Arguments
X
The observed point pattern, from which an estimate of the multitype $J$ function $J_{ij}(r)$ will be computed. It must be a multitype point pattern (a marked point pattern whose marks are a factor). See under Details.
i
The type (mark value) of the points in X from which distances are measured. A character string (or something that will be converted to a character string). Defaults to the first level of marks(X).
j
The type (mark value) of the points in X to which distances are measured. A character string (or something that will be converted to a character string). Defaults to the second level of marks(X).
eps
A positive number. The resolution of the discrete approximation to Euclidean distance (see below). There is a sensible default.
r
Optional. Numeric vector. The values of the argument $r$ at which the function $J_{ij}(r)$ should be evaluated. There is a sensible default. First-time users are strongly advised not to specify this argument. See below for important co
breaks
An alternative to the argument r. Not normally invoked by the user. See the Details section.
...
Ignored.
correction
Optional. Character string specifying the edge correction(s) to be used. Options are "none", "rs", "km", "Hanisch" and "best".
##### Details

This function Jcross and its companions Jdot and Jmulti are generalisations of the function Jest 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. The argument X must be a point pattern (object of class "ppp") or any data that are acceptable to as.ppp. It must be a marked point pattern, and the mark vector X$marks must be a factor. The argument 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 type $j$'' multitype $J$ function of a stationary multitype point process $X$ was introduced by Van lieshout and Baddeley (1999). It is defined by $$J_{ij}(r) = \frac{1 - G_{ij}(r)}{1 - F_{j}(r)}$$ where $G_{ij}(r)$ is the distribution function of the distance from a type $i$ point to the nearest point of type $j$, and $F_{j}(r)$ is the distribution function of the distance from a fixed point in space to the nearest point of type $j$ in the pattern.

An estimate of $J_{ij}(r)$ is a useful summary statistic in exploratory data analysis of a multitype point pattern. If the subprocess of type $i$ points is independent of the subprocess of points of type $j$, then $J_{ij}(r) \equiv 1$. Hence deviations of the empirical estimate of $J_{ij}$ from the value 1 may suggest dependence between types.

##### References

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.

##### See Also

Jdot, Jest, Jmulti

• Jcross
##### Examples
# Lansing woods data: 6 types of trees
data(lansing)

<testonly>lansing <- lansing[seq(1,lansing\$n, by=30), ]</testonly>
Jhm <- Jcross(lansing, "hickory", "maple")
# diagnostic plot for independence between hickories and maples
plot(Jhm)

# synthetic example with two types "a" and "b"
pp <- runifpoint(30) %mark% factor(sample(c("a","b"), 30, replace=TRUE))
J <- Jcross(pp)
Documentation reproduced from package spatstat, version 1.34-1, License: GPL (>= 2)

### Community examples

Looks like there are no examples yet.