Description Usage Arguments Details Value References See Also Examples
This function estimates the F-function in a set of homogenous or nonhomogeneous point processes, D. The F-function is evaluated in a grid of values r, and it can be optionally plotted.
It calls the auxiliary functions NHFaux and other functions not intended for users.
1 2 |
lambdaD |
A matrix of positive values. Each column is the intensity vector of one of the point process in D. If there is only one process in D, it can be a vector or even a numeric value if the process is homogeneous. |
T |
Numeric value. Length of the observed period. It only must be specified
if the number of rows in |
Ptype |
Optional. Label: "hom" or "inhom". The first one indicates that all the point processes in sets C and D are homogeneous. |
posD |
Numeric vector. Occurrence times of the points in all the point processes in D. |
typeD |
Numeric vector with the same length as |
r |
Numeric vector. Values where the F-function must be evaluated. If it is NULL, a default vector is used, see Details |
L |
Optional. Numeric vector. Values in the observed period used to calculate the F-function. If it is NULL, a default vector is used, see Details. |
dplot |
Optional. Logical flag. If it is true, the F-function is plotted. |
tit |
Optional. The title to be used in the plot of the F-function. |
... |
Further arguments to be passed to the function |
The information about the processes is provided by arguments posD
, the vector of all the occurrence times
in the processes in C, and typeD
, the vector of the code of the point process in set D
where each point in posD
has occurred.
This function estimates the F-function in a set D of homogenous or nonhomogeneous time point processes, see Cebrian et al (2020) for details of the estimation. The F-function, also known as empty space function, is the distribution function of the distances from an arbitray point in the space to the nearest point in a process in D. In homogeneous processes, it estimates the probability that at least one point in processes in D occurs at a distance lower than r of an arbitray point in the space. If the processes are nonhomogenous, the inhomogenous version of the function, adjusted for time varying intensities, is used.
If argument r
is NULL, the following grid is used to evaluate the function
r1<-max(20, floor(T/20))
r<-seq(1,r1,by=2)
if (length(r)>200) r<-seq(1,r1,length.out=200)
If argument L
is NULL, the following grid is used
L <- seq(1, T, by = 2) if (length(L) > 5000) L <- seq(1, T, by = round((T - 1)/199))
A list with elements:
r |
Vector of values r where the F-function is estimated. |
NHFr |
Estimated values of F_{D}(r). |
T |
Length of the observed period of the process. |
L |
Grid of L values to calculate the F-funtion. |
Cebrian, A.C., Abaurrea, J. and Asin, J. (2020). Testing independence between two point processes in time. Journal of Simulation and Computational Statistics.
1 2 3 4 5 6 7 8 9 10 11 12 13 | set.seed(123)
lambda1<-runif(500, 0.05, 0.1)
pos1<-simNHPc(lambda=lambda1, fixed.seed=123)$posNH
aux<-NHF(lambdaD=lambda1, posD=pos1, typeD=1)
aux$NHFr
#Set D with two processes ***
#lambda2<-runif(1000, 0.01, 0.2)
#pos2<-simNHPc(lambda=lambda2, fixed.seed=123)$posNH
#aux<-NHF(lambdaD=cbind(lambda1,lambda2), posD=c(pos1,pos2),
# typeD=c(rep(1, length(pos1)), rep(2, length(pos2))) )
#aux$NHFr
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.