tick.hawkes.SimuPoissonProcess

class tick.hawkes.SimuPoissonProcess(intensities, end_time=None, max_jumps=None, verbose=True, seed=None)[source]

Homogeneous Poisson process simulation

Parameters

intensities : float or a np.ndarray

The intensities of the poisson process. If float this Poisson process has one node, otherwise it is multidimensional

end_time : float, default=None

Time until which this point process will be simulated

max_jumps : int, default=None

Simulation will stop if this number of jumps in reached

seed : int, default = None

The seed of the random sampling. If it is None then a random seed (different at each run) will be chosen.

verbose : bool, default=True

If True, simulation information is printed

Attributes

n_nodes : int

The number of nodes of the point process

end_time : float

Time until which this point process has been simulated

n_total_jumps : int

Total number of jumps simulated

timestamps : list of np.ndarray, size=n_nodes

A list of n_nodes timestamps arrays, each array containing the timestamps of all the jumps for this node

tracked_intensity : list[np.ndarray], size=n_nodes

A record of the intensity with which this point process has been simulated. Note: you must call track_intensity before simulation to record it

intensity_tracked_times : np.ndarray

The times at which intensity has been recorded. Note: you must call track_intensity before simulation to record it

intensity_track_step : float

Step with which the intensity has been recorded

__init__(intensities, end_time=None, max_jumps=None, verbose=True, seed=None)[source]

Initialize self. See help(type(self)) for accurate signature.

is_intensity_tracked()

Is intensity tracked thanks to track_intensity or not

reset()

Reset the process, so that is is ready for a brand new simulation

simulate()

Launch the simulation of data

threshold_negative_intensity(allow=True)

Threshold intensity to 0 if it becomes negative. This allows simulation with negative kernels

Parameters

allow : bool

Flag to allow negative intensity thresholding

track_intensity(intensity_track_step=-1)

Activate the tracking of the intensity

Parameters

intensity_track_step : float

If positive then the step the intensity vector is recorded every, otherwise, it is deactivated.

Notes

This method must be called before simulation

Examples using tick.hawkes.SimuPoissonProcess