contiguity: Computation of the contiguity matrix W

View source: R/contiguity.R

Computation of the contiguity matrix WR Documentation

Computation of the contiguity matrix W

Description

Computation of the contiguity matrix W.

Usage

contiguity(coords, k = 10)

Arguments

coords

A matrix with the coordinates of the locations. The first column is the latitude and the second is the longitude.

k

The number of nearest neighbours to consider for the contiguity matrix.

Value

The contiguity matrix W. A square matrix with row standardised values (the elements of each row sum to 1).

Author(s)

Michail Tsagris.

R implementation and documentation: Michail Tsagris mtsagris@uoc.gr.

See Also

alfa.slx, cv.alfaslx, me.aslx

Examples

data(fadn)
W <- contiguity(fadn[, 1:2])

CompositionalSR documentation built on March 28, 2026, 5:07 p.m.