ComplPos: Changes format of the vector of occurrence times in a point process
Description
It changes the format of the vector of occurrence points in a point process. It builds a vector of
length T, the length of the observation period, which takes value 0 at the non occurrence times and
the position value (type="Pos"), or 1 (type="Bin"), at the occurence times.
Usage
ComplPos(pos, T, type='Pos')
Arguments
pos
Numeric vector. Occurrence times.
T
Integer. Length of the observed period.
type
Character string, 'Pos' or 'Bin'. Type of the new format.
Value
Npos
Numeric vector of lenght T containing the occurrence times in the new format.
Details
This function changes the format of the occurrence points in a point process. The new format is useful
when several point processes, in the same observed period, must be specfied; for example, in function
NHJ or NHD, where the occurrence times of different point processes
must be introduced as a matrix. Since the number of occurrences in each process can be different,
in the new format, occurrences in each process are specified as a vector of length T, which takes value 0
at non occurrence times and the time position (if type='Pos') or 1 (if type='Bin') at the occurrence times.