pcfcross {spatstat.explore}R Documentation

Multitype pair correlation function (cross-type)

Description

Calculates an estimate of the cross-type pair correlation function for a multitype point pattern.

Usage

  pcfcross(X, i, j, ..., 
           r = NULL, 
           kernel = "epanechnikov", bw = NULL, stoyan = 0.15,
           correction = c("isotropic", "Ripley", "translate"),
           divisor = c("r", "d"),
           ratio = FALSE)

Arguments

X

The observed point pattern, from which an estimate of the cross-type pair correlation function gij(r)g_{ij}(r) will be computed. It must be a multitype point pattern (a marked point pattern whose marks are a factor).

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).

...

Ignored.

r

Vector of values for the argument rr at which g(r)g(r) should be evaluated. There is a sensible default.

kernel

Choice of smoothing kernel, passed to density.default.

bw

Bandwidth for smoothing kernel, passed to density.default.

stoyan

Coefficient for default bandwidth rule; see Details.

correction

Choice of edge correction.

divisor

Choice of divisor in the estimation formula: either "r" (the default) or "d". See Details.

ratio

Logical. If TRUE, the numerator and denominator of each edge-corrected estimate will also be saved, for use in analysing replicated point patterns.

Details

The cross-type pair correlation function is a generalisation of the pair correlation function pcf to multitype point patterns.

For two locations xx and yy separated by a distance rr, the probability p(r)p(r) of finding a point of type ii at location xx and a point of type jj at location yy is

p(r)=λiλjgi,j(r)dxdy p(r) = \lambda_i \lambda_j g_{i,j}(r) \,{\rm d}x \, {\rm d}y

where λi\lambda_i is the intensity of the points of type ii. For a completely random Poisson marked point process, p(r)=λiλjp(r) = \lambda_i \lambda_j so gi,j(r)=1g_{i,j}(r) = 1. Indeed for any marked point pattern in which the points of type i are independent of the points of type j, the theoretical value of the cross-type pair correlation is gi,j(r)=1g_{i,j}(r) = 1.

For a stationary multitype point process, the cross-type pair correlation function between marks ii and jj is formally defined as

gi,j(r)=Ki,j(r)2πr g_{i,j}(r) = \frac{K_{i,j}^\prime(r)}{2\pi r}

where Ki,jK_{i,j}^\prime is the derivative of the cross-type KK function Ki,j(r)K_{i,j}(r). of the point process. See Kest for information about K(r)K(r).

The command pcfcross computes a kernel estimate of the cross-type pair correlation function between marks ii and jj.

There is also a choice of spatial edge corrections (which are needed to avoid bias due to edge effects associated with the boundary of the spatial window): correction="translate" is the Ohser-Stoyan translation correction, and correction="isotropic" or "Ripley" is Ripley's isotropic correction.

The choice of smoothing kernel is controlled by the argument kernel which is passed to density. The default is the Epanechnikov kernel.

The bandwidth of the smoothing kernel can be controlled by the argument bw. Its precise interpretation is explained in the documentation for density.default. For the Epanechnikov kernel with support [h,h][-h,h], the argument bw is equivalent to h/5h/\sqrt{5}.

If bw is not specified, the default bandwidth is determined by Stoyan's rule of thumb (Stoyan and Stoyan, 1994, page 285) applied to the points of type j. That is, h=c/λh = c/\sqrt{\lambda}, where λ\lambda is the (estimated) intensity of the point process of type j, and cc is a constant in the range from 0.1 to 0.2. The argument stoyan determines the value of cc.

The companion function pcfdot computes the corresponding analogue of Kdot.

Value

An object of class "fv", see fv.object, which can be plotted directly using plot.fv.

Essentially a data frame containing columns

r

the vector of values of the argument rr at which the function gi,jg_{i,j} has been estimated

theo

the theoretical value gi,j(r)=1g_{i,j}(r) = 1 for independent marks.

together with columns named "border", "bord.modif", "iso" and/or "trans", according to the selected edge corrections. These columns contain estimates of the function gi,jg_{i,j} obtained by the edge corrections named.

Author(s)

Adrian Baddeley Adrian.Baddeley@curtin.edu.au and Rolf Turner rolfturner@posteo.net

See Also

Mark connection function markconnect.

Multitype pair correlation pcfdot, pcfmulti.

Pair correlation pcf,pcf.ppp.

Kcross

Examples

 p <- pcfcross(amacrine, "off", "on")
 p <- pcfcross(amacrine, "off", "on", stoyan=0.1)
 plot(p)

[Package spatstat.explore version 3.3-1 Index]