Description Usage Arguments Details Value Note See Also
Function to calculate the (relative) probability of assigning an irregular unit to a neighboring regular unit.
1 | gail_rap(rUnits, iUnits, rUclose, rUdist, max_dist, method, index_val)
|
rUnits |
Data frame of regular spatial units. |
iUnits |
Data frame of irregular spatial unit being allocated. |
rUclose |
The set of regular units that are considered close (within |
rUdist |
Vector of distances of |
max_dist |
The maximum distance at which two locations can be considered neighbors. |
method |
The method of allocation, see details. |
index_val |
If |
method = "index" : the variable given by index_val (in rUnits) is used in the form X / sum(X).
method = "equal" : all neighboring spatial units (in rUclose) are given equal probability.
method = "icd" : inverse centroid distance, the closer the centroid of a regular spatial unit,
the higher the probability. If D is the distance to the centroid, the probabilities are given by:
(1/D) / sum(1/D) = 1 / ( D * sum(1/D) ). Similar to the index method, but uses a computed variable.
Returns a set of weights which has length equal to the number of spatial units in rUclose.
This is an internal function designed to be used within gail. This function
provides several default options for the RAP argument to gail. Users can alternatively
supply a custom function as the argument for the RAP argument in gail, provided it accepts
the same arguments and the returns is the same type and dimension.
The returned value is passed to sample as the argument prob.
gail
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.