Description Usage Arguments Details Value See Also Examples
Given the occurrence points in two point processes, this function calculates for each point in the first process, the distance to the nearest occurrence point in the second process.
1 | nearestdist(posx, posy)
|
posx |
Numeric vector. Occurrence times of the points in the first point process. |
posy |
Numeric vector. Occurrence times of the points in the second point process. |
The distance between two points x_i and y_i in a point process in time, is the absolute value of their difference: |x_i-y_i|.
To obtain the vector of nearest points, this function applies to each point in posx
,
the function pdist
, which calculates the distance to its nearest point in posy
.
Vector of the distances to the nearest point in the second process for each point in the first process.
1 2 3 | posx<-c(3,8,23,54,57,82)
posy<-c(2,8,14,16,29,32,45,55,65)
nearestdist(posx, posy)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.