Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

Ksector

Sector K-function


Description

A directional counterpart of Ripley's K function, in which pairs of points are counted only when the vector joining the pair happens to lie in a particular range of angles.

Usage

Ksector(X, begin = 0, end = 360, ...,
        units = c("degrees", "radians"), 
        r = NULL, breaks = NULL,
        correction = c("border", "isotropic", "Ripley", "translate"),
        domain=NULL, ratio = FALSE, verbose=TRUE)

Arguments

X

The observed point pattern, from which an estimate of K(r) will be computed. An object of class "ppp", or data in any format acceptable to as.ppp().

begin,end

Numeric values giving the range of angles inside which points will be counted. Angles are measured in degrees (if units="degrees", the default) or radians (if units="radians") anti-clockwise from the positive x-axis.

...

Ignored.

units

Units in which the angles begin and end are expressed.

r

Optional. Vector of values for the argument r at which K(r) should be evaluated. Users are advised not to specify this argument; there is a sensible default.

breaks

This argument is for internal use only.

correction

Optional. A character vector containing any selection of the options "none", "border", "bord.modif", "isotropic", "Ripley", "translate", "translation", "none", "good" or "best". It specifies the edge correction(s) to be applied. Alternatively correction="all" selects all options.

domain

Optional window. The first point x[i] of each pair of points will be constrained to lie in domain.

ratio

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

verbose

Logical value indicating whether to print progress reports and warnings.

Details

This is a directional counterpart of Ripley's K function (see Kest) in which, instead of counting all pairs of points within a specified distance r, we count only the pairs x[i], x[j] for which the vector x[j] - x[i] falls in a particular range of angles.

This can be used to evaluate evidence for anisotropy in the point pattern X.

Value

An object of class "fv" containing the estimated function.

Author(s)

and Ege Rubak rubak@math.aau.dk

See Also

Examples

K <- Ksector(swedishpines, 0, 90)
 plot(K)

spatstat.core

Core Functionality of the 'spatstat' Family

v2.1-2
GPL (>= 2)
Authors
Adrian Baddeley [aut, cre], Rolf Turner [aut], Ege Rubak [aut], Kasper Klitgaard Berthelsen [ctb], Achmad Choiruddin [ctb], Jean-Francois Coeurjolly [ctb], Ottmar Cronie [ctb], Tilman Davies [ctb], Julian Gilbey [ctb], Yongtao Guan [ctb], Ute Hahn [ctb], Kassel Hingee [ctb], Abdollah Jalilian [ctb], Marie-Colette van Lieshout [ctb], Greg McSwiggan [ctb], Tuomas Rajala [ctb], Suman Rakshit [ctb], Dominic Schuhmacher [ctb], Rasmus Plenge Waagepetersen [ctb], Hangsheng Wang [ctb]
Initial release
2021-04-17

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.