h.fn.exp: Mean Intensity of the Self-Exciting Point Process With an...

View source: R/mint.R

h.fn.expR Documentation

Mean Intensity of the Self-Exciting Point Process With an Exponential Excitation Function

Description

h.fn.exp calculates the mean intensity function h(t) which solves the integral equation

h(t)=ν(t)+\int_0^t g(t-s)h(s)ds, t≥q 0

, where the excitation function is exponential: g(t)= γ_1 e^{-γ_2t}.

Usage

h.fn.exp(x, nu, g.p = c(4, 8))

Arguments

x

numerical scalar, at which the mean intensity h is to be evaluated

nu

a function, which gives the baseline event rate

g.p

a numeric vector of two elements giving the two parameters γ_1,γ_2 of the exponential excitation function

Value

a numric scalar which gives the value of the function h at x.

See Also

h.fn

Examples

nu <- function(x)200+100*cos(pi*x);
x <- 1:500/100;
y <- sapply(x,h.fn.exp,nu=nu,g.p=c(2,1));
h <- splinefun(x,y);
g <- function(x)2*exp(-x)
round(nu(x)+sapply(x,function(x)integrate(function(u)g(x-u)*h(u),0,x)$value) - y,5)

IHSEP documentation built on Sept. 17, 2022, 1:05 a.m.