ACL: A function to compute Absolute Clustering Index (ACL)

Description Usage Arguments Value References See Also Examples

View source: R/SegFunctions.R

Description

The absolute clustering index, ACL, expresses the average number of a group's members in nearby spatial units, as a proportion of the total population in those spatial units. The spatial interactions can be expressed as a contiguity matrix (with diagonal equal to 1), as an inverse exponential function of the distance between spatial units centers (with diagonal equal to 0.6 of the square root of each spatial units area) or other user specified interaction matrix. The function can be used in two ways: to provide a spatial interactions matrix (a contiguity matrix or a distance matrix) or a external geographic information source (spatial object or shape file).

Usage

1
2
ACL(x, spatmat = 'c', c = NULL, queen = FALSE, d = NULL, distin = 'm',  
distout = 'm', diagval = '0', beta = 1, spatobj = NULL, folder = NULL, shape = NULL)

Arguments

x

- an object of class matrix (or which can be coerced to that class), where each column represents the distribution of a group within spatial units. The number of columns should be greater than 1 (at least 2 groups are required). You should not include a column with total population, because this will be interpreted as a group.

spatmat

- the method used for spatial calculations: 'c' for the contiguity matrix (by default) or any other user spatial interaction matrix and 'd' for the inverse exponential function of the distance.

c

- a modified binary contiguity (adjacency) symmetric matrix where each element Cij equals 1 if i-th and j-th spatial units are adjacent or identical, and 0 otherwise.

queen

- logical parameter difining criteria used for contiguity matrix computation, TRUE for queen, FALSE (by default) for rook

d

- a matrix of the distances between spatial unit centroids

distin

- input metric conversion, based on bink package and includes conversions from 'm', 'km', 'inch', 'ft', 'yd', 'mi', 'naut_mi', etc.

distout

- output metric conversion, based on bink package and includes conversions to 'm', 'km', 'inch', 'ft', 'yd', 'mi', 'naut_mi', etc.

diagval

- when providing a spatial object or a shape file, the user has the choice of the spatial matrix diagonal definition: diagval = '0' (by default) for an null diagonal and diagval = 'a' to compute the diagonal as 0.6 * square root (spatial/organizational unitsarea) (White, 1983)

beta

- distance decay parameter

spatobj

- a spatial object (SpatialPolygonsDataFrame) with geographic information

folder

- a character vector with the folder (directory) name indicating where the shapefile is located on the drive

shape

- a character vector with the name of the shapefile (without the .shp extension).

Value

a numeric vector containing Absolute Clustering index value for each group

References

Massey D. S. and Denton N. A. (1988) The dimensions of residential segregation. Social Forces 67(2), pp. 281-315.

See Also

Proximity measures: Pxx, Pxy, Poo, SP

Relative Clustering Index: RCL

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
x <- segdata@data[ ,1:2]
contiguity <- contig(segdata)
diag(contiguity) <- 1
ar<-area(segdata)
dist <- distance(segdata)
diag(dist)<-sqrt(ar) * 0.6
foldername <- system.file('extdata', package = 'OasisR')
shapename <- 'segdata'

ACL(x, c = contiguity) 

ACL(x, spatobj = segdata)

ACL(x, spatmat = 'd', folder = foldername, shape = shapename) 
 
ACL(x,  spatmat = 'd', diagval = 'a', spatobj = segdata)

ACL(x, d = dist, spatmat = 'd')

OasisR documentation built on July 2, 2020, 3:14 a.m.

Related to ACL in OasisR...