Aindex: R function for calculating the Hodder-Okell's A index of...

Description Usage Arguments Details See Also Examples

View source: R/Aindex.R

Description

The function allows to calculate the Hodder-Okell's A index of spatial association between the features of two point patterns.

Usage

1
Aindex(x, y, studyplot = NULL, B = 199, addmap = FALSE)

Arguments

x:

point pattern (SpatialPointDataframe class).

y:

point pattern (SpatialPointDataframe class).

studyplot:

feature (of polygon type; SpatialPolygonsDataFrame class) representing the study area; if not provided, the study area is internally worked out as the bounding polygon based on the union the convex hulls of the x and y patterns. This is only used for visualization purpose, should the user want to plot the two point patterns within the actualy study area.

addmap:

FALSE (default) or TRUE if the user does not want or wants a map of the study area and of the two patterns to be displayed.

Details

The functions takes as input two point patterns (SpatialPointDataframe class) and calculate the A index. Details about the latter are provided by:
Orton C. 1980, "Mathematics in Archeology", Glasgow: William Collins Sons & Co Ltd, pp. 154-155
Blankholm P. 1990, "Intrasite spatial Analysis in Theory and Practice", Aarhus: Aarhus University Press, pp. 130-135.

The A index is about equal to 1 when the two patterns are randomly mingled; it is smaller than 1 when the two patterns are segregrated; it is larger than 1 when the features of the two point patterns tend to occur together. The computational details are provided by Blankholm's book cited above (page 132).

The significance of the A index is calculated via the randomized approach devised by:
Kintigh K W. 1990, <e2><80><9c>Intrasite Spatial Analysis: A Commentary of Major Methids<e2><80><9d>. In Voorrips A, <e2><80><9c>Mathematics and Information Science in Archaeology: A Flexible Framework<e2><80><9d>, Studies in Modern Archaeology 3: 165-200

Given two patterns A and B being analysed, the procedure keeps the points location unchanged and randomly assigns the points to either pattern. The random re-assigment is performed B times (199 by default) and each time the A index is calculated. One-tailed and two-tailed p values are calculated following the procedure described by Baddeley et al., "Spatial Point Patterns. Methodology and Applications with R", CRC Press 2016, p. 387.

The function produces:
-an histogram showing the frequency distribution of the randomized A index, with vertical reference lines representing the 0.025th and 0.975th quantile of the distribution. A black dot represents the observed A index. At the bottom of the chart the randomized p values are reported;
-optionally (setting the 'addmap' parameter to TRUE), a map showing the point patterns (and the study area, if supplied).

See Also

distRandSign , distCovarModel , pointsCovarModel

Examples

1
2
3
4
data("malta_polyg") # load a sample polygon
pA <- spsample(malta_polyg, n=30, type='random')  #create a set of 30 random points within the polygon
pB <- spsample(malta_polyg, n=40, type='random')  #create a set of 40 random points within the polygon
Aindex(pA,pB) # calculate the Hodder-Okell's A index for the two patterns

gianmarcoalberti/GmAMisc documentation built on May 3, 2019, 6:44 p.m.